Skip to content

Commit 80de681

Browse files
authored
Add Community Calendar (#14)
* add community calendar Signed-off-by: maxwolfs <[email protected]> * remove import Signed-off-by: maxwolfs <[email protected]> Signed-off-by: maxwolfs <[email protected]>
1 parent 97125cd commit 80de681

File tree

11 files changed

+215
-154
lines changed

11 files changed

+215
-154
lines changed

community/calendar.mdx

+13
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
---
2+
sidebar_position: 2
3+
title: Calendar
4+
---
5+
6+
import CommunityCalendar from "../src/components/CommunityCalendar";
7+
8+
# Calendar
9+
10+
## We’re an open community
11+
Our meetings are publicly announced and we are happy to welcome both newcomers and established members alike. You can navigate either through the calendar below or subscribe with your favorite client to https://sovereigncloudstack.github.io/calendar/scs.ics. The calendar is collaboratively maintained on GitHub and new entries, such as a lightning talk, are highly appreciated!
12+
13+
<CommunityCalendar />

community/index.mdx

+17
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
---
2+
sidebar_position: 1
3+
title: Overview
4+
---
5+
6+
import CommunityCalendar from "../src/components/CommunityCalendar";
7+
8+
# Welcome to our SCS Community
9+
10+
## Contribute to Sovereign Cloud Stack
11+
Sovereign Cloud Stack is an open community of providers and end-users joining forces in defining, implementing and operating a fully open, federated, compatible platform. We actively encourage you to contribute either code, documentation or issues and to participate in the various discussions happening on GitHub or during our various meetings.
12+
13+
## We’re chatty
14+
We have created an open community space on the Matrix network. Feel free to join the several channels and start interacting with the community. A good starting point is entering the General & Announcements and the Tech channel.
15+
16+
## We’re on GitHub
17+
We’re actively developing, discussing and planning on GitHub. The three technical teams are using a joint project board to plan and monitor the progress during our sprints.

docs/contribute/quickstart.md

-3
This file was deleted.

docusaurus.config.js

+123-116
Original file line numberDiff line numberDiff line change
@@ -1,130 +1,137 @@
11
// @ts-check
22
// Note: type annotations allow type checking and IDEs autocompletion
33

4-
const lightCodeTheme = require("prism-react-renderer/themes/github");
5-
const darkCodeTheme = require("prism-react-renderer/themes/dracula");
4+
const lightCodeTheme = require('prism-react-renderer/themes/github')
5+
const darkCodeTheme = require('prism-react-renderer/themes/dracula')
66

77
/** @type {import('@docusaurus/types').Config} */
88
const config = {
9-
title: "Sovereign Cloud Stack Documentation",
10-
tagline: "One platform - standardized, built and operated by many.",
11-
url: "https://docs.scs.community.com",
12-
baseUrl: "/",
13-
onBrokenLinks: "throw",
14-
onBrokenMarkdownLinks: "warn",
15-
favicon: "img/favicon.ico",
9+
title: 'Sovereign Cloud Stack Documentation',
10+
tagline: 'One platform - standardized, built and operated by many.',
11+
url: 'https://docs.scs.community.com',
12+
baseUrl: '/',
13+
onBrokenLinks: 'throw',
14+
onBrokenMarkdownLinks: 'warn',
15+
favicon: 'img/favicon.ico',
1616

17-
// GitHub pages deployment config.
18-
// If you aren't using GitHub pages, you don't need these.
19-
organizationName: "SovereignCloudStack", // Usually your GitHub org/user name.
20-
projectName: "docs-page", // Usually your repo name.
17+
// GitHub pages deployment config.
18+
// If you aren't using GitHub pages, you don't need these.
19+
organizationName: 'SovereignCloudStack', // Usually your GitHub org/user name.
20+
projectName: 'docs-page', // Usually your repo name.
2121

22-
// Even if you don't use internalization, you can use this field to set useful
23-
// metadata like html lang. For example, if your site is Chinese, you may want
24-
// to replace "en" with "zh-Hans".
25-
i18n: {
26-
defaultLocale: "en",
27-
locales: ["en"],
28-
},
22+
// Even if you don't use internalization, you can use this field to set useful
23+
// metadata like html lang. For example, if your site is Chinese, you may want
24+
// to replace "en" with "zh-Hans".
25+
i18n: {
26+
defaultLocale: 'en',
27+
locales: ['en']
28+
},
2929

30-
presets: [
31-
[
32-
"classic",
33-
/** @type {import('@docusaurus/preset-classic').Options} */
34-
({
35-
docs: {
36-
sidebarPath: require.resolve("./sidebars.js"),
37-
// Please change this to your repo.
38-
// Remove this to remove the "edit this page" links.
39-
editUrl:
40-
"https://github.com/SovereignCloudStack/docs-page/tree/main/",
41-
},
42-
blog: {
43-
showReadingTime: true,
44-
// Please change this to your repo.
45-
// Remove this to remove the "edit this page" links.
46-
editUrl:
47-
"https://github.com/SovereignCloudStack/docs-page/tree/main/"
48-
},
49-
theme: {
50-
customCss: require.resolve("./src/css/custom.css"),
51-
},
52-
}),
53-
],
54-
],
30+
presets: [
31+
[
32+
'classic',
33+
/** @type {import('@docusaurus/preset-classic').Options} */
34+
({
35+
docs: {
36+
sidebarPath: require.resolve('./sidebars.js'),
37+
editUrl: 'https://github.com/SovereignCloudStack/docs-page/tree/main/'
38+
},
39+
blog: {
40+
showReadingTime: true,
41+
editUrl: 'https://github.com/SovereignCloudStack/docs-page/tree/main/'
5542

56-
themeConfig:
43+
},
44+
theme: {
45+
customCss: [require.resolve('./src/css/custom.css')]
46+
}
47+
})
48+
]
49+
],
50+
plugins: [
51+
[
52+
'@docusaurus/plugin-content-docs',
53+
{
54+
id: 'community',
55+
path: 'community',
56+
routeBasePath: 'community',
57+
sidebarPath: require.resolve('./sidebarsCommunity.js')
58+
// ... other options
59+
}
60+
]
61+
],
62+
63+
themeConfig:
5764
/** @type {import('@docusaurus/preset-classic').ThemeConfig} */
5865
({
59-
navbar: {
60-
title: "",
61-
logo: {
62-
alt: "My Site Logo",
63-
src: "img/logo.svg",
64-
},
65-
items: [
66-
{
67-
type: "doc",
68-
docId: "intro",
69-
position: "left",
70-
label: "Docs",
71-
},
72-
{ to: "/blog", label: "Blog", position: "left" },
73-
{
74-
href: "https://github.com/SovereignCloudStack/docs-page",
75-
label: "GitHub",
76-
position: "right",
77-
},
78-
],
79-
},
80-
footer: {
81-
style: "dark",
82-
links: [
83-
{
84-
title: "Docs",
85-
items: [
86-
{
87-
label: "Contribute",
88-
to: "/docs/intro",
89-
},
90-
],
91-
},
92-
{
93-
title: "Community",
94-
items: [
95-
{
96-
label: "Matrix",
97-
href: "https://matrix.to/#/!TiDqlLmEUaXqTemaLc:matrix.org?via=matrix.org",
98-
},
99-
{
100-
label: "Twitter",
101-
href: "https://twitter.com/scs_osballiance",
102-
},
103-
],
104-
},
105-
{
106-
title: "More",
107-
items: [
108-
{
109-
label: "Blog",
110-
to: "/blog",
111-
},
112-
{
113-
label: "GitHub",
114-
href: "https://github.com/SovereignCloudStack/docs-page",
115-
},
116-
],
117-
},
118-
],
119-
copyright:
120-
"Sovereign Cloud Stack, SCS and the logo are registered trademarks of the Open Source Business Alliance e.V. — Other trademarks are property of their respective owners.",
121-
},
122-
prism: {
123-
theme: lightCodeTheme,
124-
darkTheme: darkCodeTheme,
125-
additionalLanguages: ["powershell", "ruby"],
66+
navbar: {
67+
title: '',
68+
logo: {
69+
alt: 'My Site Logo',
70+
src: 'img/logo.svg'
12671
},
127-
}),
128-
};
72+
items: [
73+
{
74+
type: 'doc',
75+
docId: 'intro',
76+
position: 'left',
77+
label: 'Docs'
78+
},
79+
// { to: '/blog', label: 'Blog', position: 'left' },
80+
{ to: '/community', label: 'Community', position: 'left' },
81+
{
82+
href: 'https://github.com/SovereignCloudStack/docs-page',
83+
label: 'GitHub',
84+
position: 'right'
85+
}
86+
]
87+
},
88+
footer: {
89+
style: 'light',
90+
links: [
91+
{
92+
title: 'Docs',
93+
items: [
94+
{
95+
label: 'Contribute',
96+
to: '/docs/intro'
97+
}
98+
]
99+
},
100+
{
101+
title: 'Community',
102+
items: [
103+
{
104+
label: 'Matrix',
105+
href: 'https://matrix.to/#/!TiDqlLmEUaXqTemaLc:matrix.org?via=matrix.org'
106+
},
107+
{
108+
label: 'Twitter',
109+
href: 'https://twitter.com/scs_osballiance'
110+
}
111+
]
112+
},
113+
{
114+
title: 'More',
115+
items: [
116+
{
117+
label: 'Blog',
118+
to: '/blog'
119+
},
120+
{
121+
label: 'GitHub',
122+
href: 'https://github.com/SovereignCloudStack/docs-page'
123+
}
124+
]
125+
}
126+
],
127+
copyright: 'Sovereign Cloud Stack, SCS and the logo are registered trademarks of the Open Source Business Alliance e.V. — Other trademarks are property of their respective owners.'
128+
},
129+
prism: {
130+
theme: lightCodeTheme,
131+
darkTheme: darkCodeTheme,
132+
additionalLanguages: ['powershell', 'ruby']
133+
}
134+
})
135+
}
129136

130-
module.exports = config;
137+
module.exports = config

package.json

+6
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,12 @@
1818
"dependencies": {
1919
"@docusaurus/core": "2.2.0",
2020
"@docusaurus/preset-classic": "2.2.0",
21+
"@fullcalendar/core": "^6.0.1",
22+
"@fullcalendar/daygrid": "^6.0.1",
23+
"@fullcalendar/icalendar": "^6.0.1",
24+
"@fullcalendar/interaction": "^6.0.1",
25+
"@fullcalendar/react": "^6.0.1",
26+
"@fullcalendar/timegrid": "^6.0.1",
2127
"@mdx-js/react": "^1.6.22",
2228
"clsx": "^1.2.1",
2329
"prism-react-renderer": "^1.3.5",

sidebars.js

+3-28
Original file line numberDiff line numberDiff line change
@@ -1,33 +1,8 @@
1-
/**
2-
* Creating a sidebar enables you to:
3-
- create an ordered group of docs
4-
- render a sidebar for each doc of that group
5-
- provide next/previous navigation
6-
7-
The sidebars can be generated from the filesystem, or explicitly defined here.
8-
9-
Create as many sidebars as you want.
10-
*/
11-
121
// @ts-check
132

143
/** @type {import('@docusaurus/plugin-content-docs').SidebarsConfig} */
154
const sidebars = {
16-
// By default, Docusaurus generates a sidebar from the docs folder structure
17-
tutorialSidebar: [{type: 'autogenerated', dirName: '.'}],
18-
19-
// But you can create a sidebar manually
20-
/*
21-
tutorialSidebar: [
22-
'intro',
23-
'hello',
24-
{
25-
type: 'category',
26-
label: 'Tutorial',
27-
items: ['tutorial-basics/create-a-document'],
28-
},
29-
],
30-
*/
31-
};
5+
docs: [{ type: 'autogenerated', dirName: '.' }]
6+
}
327

33-
module.exports = sidebars;
8+
module.exports = sidebars

sidebarsCommunity.js

+9
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
// @ts-check
2+
3+
/** @type {import('@docusaurus/plugin-content-docs').SidebarsConfig} */
4+
module.exports = {
5+
community: [{
6+
type: 'autogenerated',
7+
dirName: '.'
8+
}]
9+
}

src/components/CommunityCalendar.tsx

+39
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,39 @@
1+
import React from "react";
2+
import FullCalendar from "@fullcalendar/react";
3+
import dayGridPlugin from "@fullcalendar/daygrid";
4+
import timeGridPlugin from "@fullcalendar/timegrid";
5+
import interactionPlugin from "@fullcalendar/interaction";
6+
import icalendarPlugin from "@fullcalendar/icalendar";
7+
8+
const CommunityCalendar: React.FunctionComponent = () => {
9+
return (
10+
<FullCalendar
11+
slotDuration="00:15:00"
12+
slotMinTime="09:00:00"
13+
slotMaxTime="18:00:00"
14+
navLinks={true}
15+
nowIndicator={true}
16+
height={"auto"}
17+
expandRows={false}
18+
plugins={[
19+
dayGridPlugin,
20+
timeGridPlugin,
21+
icalendarPlugin,
22+
interactionPlugin,
23+
]}
24+
initialView="timeGridWeek"
25+
weekends={false}
26+
events={{
27+
url: "https://sovereigncloudstack.github.io/calendar/scs.ics",
28+
format: "ics",
29+
}}
30+
headerToolbar={{
31+
left: "prev,next today",
32+
center: "title",
33+
right: "timeGridDay,timeGridWeek,dayGridMonth",
34+
}}
35+
/>
36+
);
37+
};
38+
39+
export default CommunityCalendar;

0 commit comments

Comments
 (0)