-
Notifications
You must be signed in to change notification settings - Fork 4
Tweak: Added Project Night to Activities and modified link validation #9
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,6 @@ | ||
| title: Project Night | ||
| description: A weekly virtual gathering to work on our personal projects, and share learnings. Message @aberkowitz your email for an invite. | ||
| link: "slack://channel?team=T0A0T7A5Q&id=D3KKP1X7A" | ||
| color: "#735FFF" | ||
|
Contributor
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. NoteI thought about this color way more than I should have. Hopefully the color I have chosen will not sentence me to designer hell. document.body.style.background = '#fff';
document.body.innerHTML = '<div id="container"> </div>';
container = document.getElementById('container');
let colors = ['#fb7185', '#22d3ee', '#34d399', '#c084fc', '#fbbf24', '#735FFF'];
colors.forEach( (color) => {
let color_container = document.createElement('div');
color_container.style = `height: 50px; width: 50px; background: ${color}`;
container.appendChild(color_container);
});
|
||
| order: 6 | ||
| status: ongoing | ||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -20,7 +20,7 @@ const activities = defineCollection({ | |
| schema: z.object({ | ||
| title: z.string().min(2), | ||
| description: z.string().min(10), | ||
| link: z.string().optional().refine(v => !v || v.startsWith('/') || v.startsWith('http'), { | ||
| link: z.string().optional().refine(v => !v || v.startsWith('/') || v.startsWith('http') || v.startsWith('slack'), { | ||
|
Contributor
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. SandThere's probable a better way to do this validation, but I don't care.
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. i am more interested in what happens when you click on a device that doesnt support slack. |
||
| message: 'link must be a relative path or full URL', | ||
| }), | ||
| color: z.string().regex(/^#[0-9a-fA-F]{6}$/), | ||
|
|
||

There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sand
This is a deeplink to message me in slack. Eventually, there will be a dedicated channel for the event.