From: Arnaud Guéras Date: Wed, 4 Dec 2024 17:17:24 +0000 (+0100) Subject: Squashed commit of the following: X-Git-Url: http://xenbits.xensource.com/gitweb?a=commitdiff_plain;h=4fb90c2fa9db0d5c8b3af1a91c9c93f510d1b5de;p=www-xenproject-org.git Squashed commit of the following: commit 86838c4a32f606055162a77f206362807eaad4ad Author: Arnaud Guéras Date: Wed Dec 4 18:10:38 2024 +0100 documentation Signed-off-by: Arnaud Guéras commit 8fd7c0c99dc82fe7a51068fd3fec2f702cc5849d Author: Arnaud Guéras Date: Wed Dec 4 15:42:32 2024 +0100 doc Signed-off-by: Arnaud Guéras commit e21e51f3a2d8bf4061c5571c1a8e8d7f24bfb262 Author: Arnaud Guéras Date: Tue Dec 3 20:31:38 2024 +0100 doc Signed-off-by: Arnaud Guéras --- diff --git a/.gitignore b/.gitignore index de53b55..aa81ae0 100644 --- a/.gitignore +++ b/.gitignore @@ -7,4 +7,5 @@ storybook-static .DS_Store .env -thumbs.db \ No newline at end of file +thumbs.db + diff --git a/README.md b/README.md index 7d54e9e..db0b831 100644 --- a/README.md +++ b/README.md @@ -1,25 +1,41 @@ # Xen-Project website + +## Main documentation + +All the main documentation is in the [docs](./docs) folder. + + + ## Tools - [Hugo](https://gohugo.io) - [Npm](https://www.npmjs.com) - [Sass](https://sass-lang.com) -## Running hugo +## Run the project on your computer + +Git clone the project on your computer (check how to on the main page of the project) + -How to run hugo: +Install Hugo : + +[https://gohugo.io/installation/](https://gohugo.io/installation/) + +Run Hugo : ```bash -$ +hugo server -D --logLevel debug --config hugo.yaml,hugo.dev.yaml ``` +Open the website on http://localhost:1313 + + ## Important urls -[Hugo Documentation](https://gohugo.io/getting-started/directory-structure/) -[Npm Package Hugo Extended](https://www.npmjs.com/package/hugo-extended) -[Ghost Migration from Worpress](https://ghost.org/docs/migration/wordpress/) -[Figma Design](https://www.figma.com/design/36fAO6lf2tvY5G2KwOl6eu/xenproject.org?node-id=125-28209&m=dev) +- [Hugo Documentation](https://gohugo.io/getting-started/directory-structure/) +- [Npm Package Hugo Extended](https://www.npmjs.com/package/hugo-extended) +- [Figma Design](https://www.figma.com/design/36fAO6lf2tvY5G2KwOl6eu/xenproject.org?node-id=125-28209&m=dev) ## Other resources @@ -27,4 +43,8 @@ $ ### Edit SVG : - https://editsvg.online/editor.html (copy past the SVG code and edit, and then copy the code) - https://svgomg.net/ (copy past the SVG code, optimize it, and copy the code) + +### Image Tools + +- [Sqoosh](https://squoosh.app/) Convert and reduce image size \ No newline at end of file diff --git a/TODO.md b/TODO.md deleted file mode 100644 index 59806d9..0000000 --- a/TODO.md +++ /dev/null @@ -1,3 +0,0 @@ -# TODO - -Mainlink lng \ No newline at end of file diff --git a/content/_index.md b/content/_index.md index b0cebfd..163cadb 100644 --- a/content/_index.md +++ b/content/_index.md @@ -66,7 +66,7 @@ The Xen Project focuses on revolutionizing virtualization by providing a versati - **Secure Critical Systems:** Safeguard data and applications through industry-leading security. - **Revolutionize Embedded Technologies:** Transform embedded and automotive sectors with mature, safe, secure solutions. {{}} - + {{}} diff --git a/docs/components/carousel.md b/docs/components/carousel.md new file mode 100644 index 0000000..87a86e1 --- /dev/null +++ b/docs/components/carousel.md @@ -0,0 +1,76 @@ +--- +title: "Carousel" +description: "A carousel component for displaying a rotating list of items" +--- + +# Carousel Component + +[![Carousel component](../images/carousel-thumb.png)](../images/carousel.png) + +The carousel component allows you to display a rotating list of items in a slider format with navigation buttons. + +## Basic Usage + +The most common use case is to display all projects using the `getpages` shortcode: + +```html +{{}} +{{}} +{{}} +``` + +## With Custom Class + +You can add a custom class to the carousel container: + +```html +{{}} +{{}} +{{}} +``` + +## Structure of Project Items + +When using `getpages` with "projects", each project page should have the following front matter structure: + +```yaml +--- +title: "Project Name" +description: "Short description of the project" +logo: "/path/to/logo.svg" +website: "https://project-website.com" +github: "https://github.com/organization/project" +status: "active" +--- +``` + +## HTML Structure + +The carousel component generates the following HTML structure: + +```html + +``` + +## Features + +- Responsive design +- Navigation buttons (previous/next) +- Customizable through CSS classes +- Automatic content generation from project pages diff --git a/docs/components/feature-lists.md b/docs/components/feature-lists.md new file mode 100644 index 0000000..7f9c145 --- /dev/null +++ b/docs/components/feature-lists.md @@ -0,0 +1,59 @@ +# Features List Component + +[![Features list component](../images/features-list-thumb.png)](../images/features-list.png) + +The `features-list` component allows you to display a grid of features with icons, titles, and descriptions. + +## Usage + +To use this component in your Markdown pages, use the following shortcode syntax: + +```markdown + {{}} +- title: Feature title + icon: fas fa-icon-name + description: Feature description +- title: Feature title + icon: fas fa-icon-name + description: Feature description + {{}} +``` + +## Parameters + +### Shortcode Parameters + +| Parameter | Description | Required | Default | +| --------- | ----------------------------- | -------- | ------- | +| cols | Number of columns in the grid | No | 3 | + +### Item Parameters + +Each list item must contain the following properties: + +| Property | Description | Required | +| ----------- | ----------------------- | -------- | +| title | Feature title | Yes | +| icon | Font Awesome icon class | Yes | +| description | Detailed description | Yes | + +## Example + +```markdown +{{}} +- title: Open-source + icon: fas fa-code + description: Wide variety of vendors and individuals opens new opportunities... +- title: Reliable + icon: fas fa-thumbs-up + description: Over 10 million people use Xen with an ecosystem... +{{}} +``` + +## Technical Notes + +- The component uses Font Awesome for icons +- Content is parsed as YAML using the `transform.Unmarshal` function +- Each item is rendered using the `feature-item.html` partial +- Layout is managed via CSS using the `features-list` class +``` diff --git a/docs/components/latest-news.md b/docs/components/latest-news.md new file mode 100644 index 0000000..49190f5 --- /dev/null +++ b/docs/components/latest-news.md @@ -0,0 +1,34 @@ +--- +title: "Latest News" +description: "A component for displaying the latest blog posts in a carousel" +--- + +# Latest News Component + +[![Latest news component](../images/latest-news-thumb.png)](../images/latest-news.png) + +The Latest News component displays the most recent blog posts in a carousel format with navigation buttons. It automatically fetches and displays up to 10 latest posts from the blog section. + +## Basic Usage + +To add the Latest News component to your page, use the following shortcode: + +```markdown +{{
}} +{{}} +{{
}} +``` + +## Features + +- Displays up to 10 latest blog posts +- Responsive carousel design +- Navigation buttons (previous/next) +- Automatic content generation from blog posts +- "Read all news" link to the blog section +- Displays post metadata: + - Title + - Publication date + - Tags (if available) + - Excerpt + - Author(s) (if available) diff --git a/docs/components/media-block.md b/docs/components/media-block.md new file mode 100644 index 0000000..9dc183f --- /dev/null +++ b/docs/components/media-block.md @@ -0,0 +1,52 @@ +# media-block + +[![Media block with left media position](../images/media-block--left-thumb.png)](../images/media-block--left.png) [![Media block with right media position](../images/media-block--right-thumb.png)](../images/media-block--right.png) + + +The `media-block` is a flexible component for displaying content with a media element (image, video, or other component). +```markdown +{{}} + ## A remarkable innovation + + Our revolutionary new technology improves productivity by **50%**. + Discover its main features: + + * Optimized performance + * Intuitive interface + * Maximum compatibility + + +{{}} +``` + +| Parameter | Type | Default | Description | +| --------------------- | ------ | ------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | +| `title` | string | - | Block title. Supports markdown for bold (`**text**`) and italic (`*text*`) | +| `media` | string | - | URL of image/video or shortcode of another component. Supports: images (png, jpg, jpeg, avif, webp, gif, svg), videos (mp4), YouTube, SlideShare and partial or HTML components | +| `mediaPosition` | string | "left" | Position of media element: `"left"` or `"right"` | +| `mobileMediaPosition` | string | "left" | Position of media element on mobile: `"top"` or `"bottom"` | +| `imageAlt` | string | "Media image" | Alternative text for image | +| `imageSize` | string | - | Image size (width in pixels) | +| `label` | string | - | Optional label above title | +| `titleLevel` | string | "2" | HTML title level (h1-h6) | +| `titleClass` | string | - | Additional CSS classes for title | +| `class` | string | - | Additional CSS classes for block | +| `animate` | string | "false" | Activates block animation: `"true"` or `"false"` | + +The content between the shortcode tags can include Markdown and HTML. \ No newline at end of file diff --git a/docs/components/vertical-lists.md b/docs/components/vertical-lists.md new file mode 100644 index 0000000..99e2b86 --- /dev/null +++ b/docs/components/vertical-lists.md @@ -0,0 +1,70 @@ +--- +title: "Vertical Lists Component" +description: "Documentation for the vertical-lists component" +--- + +# Vertical Lists Component + +[![Vertical lists component](../images/vertical-lists-thumb.png)](components/vertical-lists.md) + +The `vertical-lists` component allows you to create columnar layouts with titled sections. Each section can contain text, links, or other content. + +## Usage + +Basic structure: +```markdown +{{}} +- title: "**Bold** Title" + text: > +

Content for the first section

+ +- title: "Regular Title" + text: > +

Content for the second section

+{{
}} +``` + +## Parameters + +- `cols`: Number of columns to display (e.g. "2" for two columns) + +## List Item Properties + +Each list item requires: +- `title`: The section title (supports markdown formatting) +- `text`: The content (supports HTML and markdown) + +## Examples + +### Example with Mixed Title Formatting + +```markdown +{{}} +- title: "**Documentation** Resources" + text: > +

Access documentation

+ +- title: "Community Links" + text: > +

Join our community

+{{
}} +``` + +This example shows: +- First title with partial bold formatting using `**Documentation** Resources` +- Second title with no formatting +- Both sections include buttons with icons + +## Styling + +The component automatically handles: +- Column layout based on the `cols` parameter +- Consistent spacing between sections +- Responsive design for different screen sizes + +## Best Practices + +1. Use bold formatting (`**text**`) to emphasize key words in titles +2. Keep titles concise and clear +3. Maintain consistent styling across buttons and links +4. Use icons to enhance visual hierarchy and user experience \ No newline at end of file diff --git a/docs/images.md b/docs/images.md new file mode 100644 index 0000000..6267cfb --- /dev/null +++ b/docs/images.md @@ -0,0 +1,771 @@ +# Images + +This document lists all available images in the project with their paths and usage examples. + +## List of images + +### home-servers.webp + +![home-servers.webp](thumbnails/home-servers.webp) + +**Path:** `/img/decorative/home-servers.webp` + +**Usage Examples:** + +```markdown +![home-servers.webp](/img/decorative/home-servers.webp) +``` + +```markdown +home-servers.webp +``` +### home-shadow-screen.png + +![home-shadow-screen.png](thumbnails/home-shadow-screen.png) + +**Path:** `/img/decorative/home-shadow-screen.png` + +**Usage Examples:** + +```markdown +![home-shadow-screen.png](/img/decorative/home-shadow-screen.png) +``` + +```markdown +home-shadow-screen.png +``` +### home-wire.png + +![home-wire.png](thumbnails/home-wire.png) + +**Path:** `/img/decorative/home-wire.png` + +**Usage Examples:** + +```markdown +![home-wire.png](/img/decorative/home-wire.png) +``` + +```markdown +home-wire.png +``` +### screen-with-wire.svg + +![screen-with-wire.svg](thumbnails/screen-with-wire.svg) + +**Path:** `/img/decorative/screen-with-wire.svg` + +**Usage Examples:** + +```markdown +![screen-with-wire.svg](/img/decorative/screen-with-wire.svg) +``` + +```markdown +screen-with-wire.svg +``` +### cloud.png + +![cloud.png](thumbnails/cloud.png) + +**Path:** `/img/figures/cloud.png` + +**Usage Examples:** + +```markdown +![cloud.png](/img/figures/cloud.png) +``` + +```markdown +cloud.png +``` +### small-cloud.png + +![small-cloud.png](thumbnails/small-cloud.png) + +**Path:** `/img/figures/small-cloud.png` + +**Usage Examples:** + +```markdown +![small-cloud.png](/img/figures/small-cloud.png) +``` + +```markdown +small-cloud.png +``` +### xen-panda-kungfu.png + +![xen-panda-kungfu.png](thumbnails/xen-panda-kungfu.png) + +**Path:** `/img/figures/xen-panda-kungfu.png` + +**Usage Examples:** + +```markdown +![xen-panda-kungfu.png](/img/figures/xen-panda-kungfu.png) +``` + +```markdown +xen-panda-kungfu.png +``` +### xen-panda-winged.png + +![xen-panda-winged.png](thumbnails/xen-panda-winged.png) + +**Path:** `/img/figures/xen-panda-winged.png` + +**Usage Examples:** + +```markdown +![xen-panda-winged.png](/img/figures/xen-panda-winged.png) +``` + +```markdown +xen-panda-winged.png +``` +### xen-panda-zen.png + +![xen-panda-zen.png](thumbnails/xen-panda-zen.png) + +**Path:** `/img/figures/xen-panda-zen.png` + +**Usage Examples:** + +```markdown +![xen-panda-zen.png](/img/figures/xen-panda-zen.png) +``` + +```markdown +xen-panda-zen.png +``` +### brainstorming-session.svg + +![brainstorming-session.svg](thumbnails/brainstorming-session.svg) + +**Path:** `/img/flatline/brainstorming-session.svg` + +**Usage Examples:** + +```markdown +![brainstorming-session.svg](/img/flatline/brainstorming-session.svg) +``` + +```markdown +brainstorming-session.svg +``` +### brainstorming.svg + +![brainstorming.svg](thumbnails/brainstorming.svg) + +**Path:** `/img/flatline/brainstorming.svg` + +**Usage Examples:** + +```markdown +![brainstorming.svg](/img/flatline/brainstorming.svg) +``` + +```markdown +brainstorming.svg +``` +### coding.svg + +![coding.svg](thumbnails/coding.svg) + +**Path:** `/img/flatline/coding.svg` + +**Usage Examples:** + +```markdown +![coding.svg](/img/flatline/coding.svg) +``` + +```markdown +coding.svg +``` +### coding2.svg + +![coding2.svg](thumbnails/coding2.svg) + +**Path:** `/img/flatline/coding2.svg` + +**Usage Examples:** + +```markdown +![coding2.svg](/img/flatline/coding2.svg) +``` + +```markdown +coding2.svg +``` +### data-analysis.svg + +![data-analysis.svg](thumbnails/data-analysis.svg) + +**Path:** `/img/flatline/data-analysis.svg` + +**Usage Examples:** + +```markdown +![data-analysis.svg](/img/flatline/data-analysis.svg) +``` + +```markdown +data-analysis.svg +``` +### data-analyst.svg + +![data-analyst.svg](thumbnails/data-analyst.svg) + +**Path:** `/img/flatline/data-analyst.svg` + +**Usage Examples:** + +```markdown +![data-analyst.svg](/img/flatline/data-analyst.svg) +``` + +```markdown +data-analyst.svg +``` +### data-center.svg + +![data-center.svg](thumbnails/data-center.svg) + +**Path:** `/img/flatline/data-center.svg` + +**Usage Examples:** + +```markdown +![data-center.svg](/img/flatline/data-center.svg) +``` + +```markdown +data-center.svg +``` +### data-hosting.svg + +![data-hosting.svg](thumbnails/data-hosting.svg) + +**Path:** `/img/flatline/data-hosting.svg` + +**Usage Examples:** + +```markdown +![data-hosting.svg](/img/flatline/data-hosting.svg) +``` + +```markdown +data-hosting.svg +``` +### data-process-with-xen-logo.svg + +![data-process-with-xen-logo.svg](thumbnails/data-process-with-xen-logo.svg) + +**Path:** `/img/flatline/data-process-with-xen-logo.svg` + +**Usage Examples:** + +```markdown +![data-process-with-xen-logo.svg](/img/flatline/data-process-with-xen-logo.svg) +``` + +```markdown +data-process-with-xen-logo.svg +``` +### data-process.svg + +![data-process.svg](thumbnails/data-process.svg) + +**Path:** `/img/flatline/data-process.svg` + +**Usage Examples:** + +```markdown +![data-process.svg](/img/flatline/data-process.svg) +``` + +```markdown +data-process.svg +``` +### data-process2.svg + +![data-process2.svg](thumbnails/data-process2.svg) + +**Path:** `/img/flatline/data-process2.svg` + +**Usage Examples:** + +```markdown +![data-process2.svg](/img/flatline/data-process2.svg) +``` + +```markdown +data-process2.svg +``` +### data-storage.svg + +![data-storage.svg](thumbnails/data-storage.svg) + +**Path:** `/img/flatline/data-storage.svg` + +**Usage Examples:** + +```markdown +![data-storage.svg](/img/flatline/data-storage.svg) +``` + +```markdown +data-storage.svg +``` +### data_and_settings.svg + +![data_and_settings.svg](thumbnails/data_and_settings.svg) + +**Path:** `/img/flatline/data_and_settings.svg` + +**Usage Examples:** + +```markdown +![data_and_settings.svg](/img/flatline/data_and_settings.svg) +``` + +```markdown +data_and_settings.svg +``` +### error-404.svg + +![error-404.svg](thumbnails/error-404.svg) + +**Path:** `/img/flatline/error-404.svg` + +**Usage Examples:** + +```markdown +![error-404.svg](/img/flatline/error-404.svg) +``` + +```markdown +error-404.svg +``` +### handshake.svg + +![handshake.svg](thumbnails/handshake.svg) + +**Path:** `/img/flatline/handshake.svg` + +**Usage Examples:** + +```markdown +![handshake.svg](/img/flatline/handshake.svg) +``` + +```markdown +handshake.svg +``` +### java.svg + +![java.svg](thumbnails/java.svg) + +**Path:** `/img/flatline/java.svg` + +**Usage Examples:** + +```markdown +![java.svg](/img/flatline/java.svg) +``` + +```markdown +java.svg +``` +### laptop-cybersecurity.svg + +![laptop-cybersecurity.svg](thumbnails/laptop-cybersecurity.svg) + +**Path:** `/img/flatline/laptop-cybersecurity.svg` + +**Usage Examples:** + +```markdown +![laptop-cybersecurity.svg](/img/flatline/laptop-cybersecurity.svg) +``` + +```markdown +laptop-cybersecurity.svg +``` +### new-message.svg + +![new-message.svg](thumbnails/new-message.svg) + +**Path:** `/img/flatline/new-message.svg` + +**Usage Examples:** + +```markdown +![new-message.svg](/img/flatline/new-message.svg) +``` + +```markdown +new-message.svg +``` +### screen-with-xen-logo.webp + +![screen-with-xen-logo.webp](thumbnails/screen-with-xen-logo.webp) + +**Path:** `/img/flatline/screen-with-xen-logo.webp` + +**Usage Examples:** + +```markdown +![screen-with-xen-logo.webp](/img/flatline/screen-with-xen-logo.webp) +``` + +```markdown +screen-with-xen-logo.webp +``` +### security.svg + +![security.svg](thumbnails/security.svg) + +**Path:** `/img/flatline/security.svg` + +**Usage Examples:** + +```markdown +![security.svg](/img/flatline/security.svg) +``` + +```markdown +security.svg +``` +### start-up.svg + +![start-up.svg](thumbnails/start-up.svg) + +**Path:** `/img/flatline/start-up.svg` + +**Usage Examples:** + +```markdown +![start-up.svg](/img/flatline/start-up.svg) +``` + +```markdown +start-up.svg +``` +### team-meeting.svg + +![team-meeting.svg](thumbnails/team-meeting.svg) + +**Path:** `/img/flatline/team-meeting.svg` + +**Usage Examples:** + +```markdown +![team-meeting.svg](/img/flatline/team-meeting.svg) +``` + +```markdown +team-meeting.svg +``` +### team-work.svg + +![team-work.svg](thumbnails/team-work.svg) + +**Path:** `/img/flatline/team-work.svg` + +**Usage Examples:** + +```markdown +![team-work.svg](/img/flatline/team-work.svg) +``` + +```markdown +team-work.svg +``` +### timeline.svg + +![timeline.svg](thumbnails/timeline.svg) + +**Path:** `/img/flatline/timeline.svg` + +**Usage Examples:** + +```markdown +![timeline.svg](/img/flatline/timeline.svg) +``` + +```markdown +timeline.svg +``` +### logo-xen-reverse.svg + +![logo-xen-reverse.svg](thumbnails/logo-xen-reverse.svg) + +**Path:** `/img/logo-xen-reverse.svg` + +**Usage Examples:** + +```markdown +![logo-xen-reverse.svg](/img/logo-xen-reverse.svg) +``` + +```markdown +logo-xen-reverse.svg +``` +### logo-xen.svg + +![logo-xen.svg](thumbnails/logo-xen.svg) + +**Path:** `/img/logo-xen.svg` + +**Usage Examples:** + +```markdown +![logo-xen.svg](/img/logo-xen.svg) +``` + +```markdown +logo-xen.svg +``` +### amd-logo.svg + +![amd-logo.svg](thumbnails/amd-logo.svg) + +**Path:** `/img/logos/amd-logo.svg` + +**Usage Examples:** + +```markdown +![amd-logo.svg](/img/logos/amd-logo.svg) +``` + +```markdown +amd-logo.svg +``` +### arm-logo.svg + +![arm-logo.svg](thumbnails/arm-logo.svg) + +**Path:** `/img/logos/arm-logo.svg` + +**Usage Examples:** + +```markdown +![arm-logo.svg](/img/logos/arm-logo.svg) +``` + +```markdown +arm-logo.svg +``` +### aws-logo.svg + +![aws-logo.svg](thumbnails/aws-logo.svg) + +**Path:** `/img/logos/aws-logo.svg` + +**Usage Examples:** + +```markdown +![aws-logo.svg](/img/logos/aws-logo.svg) +``` + +```markdown +aws-logo.svg +``` +### epam-logo.svg + +![epam-logo.svg](thumbnails/epam-logo.svg) + +**Path:** `/img/logos/epam-logo.svg` + +**Usage Examples:** + +```markdown +![epam-logo.svg](/img/logos/epam-logo.svg) +``` + +```markdown +epam-logo.svg +``` +### honda-logo.svg + +![honda-logo.svg](thumbnails/honda-logo.svg) + +**Path:** `/img/logos/honda-logo.svg` + +**Usage Examples:** + +```markdown +![honda-logo.svg](/img/logos/honda-logo.svg) +``` + +```markdown +honda-logo.svg +``` +### logo-linux-foundation.svg + +![logo-linux-foundation.svg](thumbnails/logo-linux-foundation.svg) + +**Path:** `/img/logos/logo-linux-foundation.svg` + +**Usage Examples:** + +```markdown +![logo-linux-foundation.svg](/img/logos/logo-linux-foundation.svg) +``` + +```markdown +logo-linux-foundation.svg +``` +### vates-logo.svg + +![vates-logo.svg](thumbnails/vates-logo.svg) + +**Path:** `/img/logos/vates-logo.svg` + +**Usage Examples:** + +```markdown +![vates-logo.svg](/img/logos/vates-logo.svg) +``` + +```markdown +vates-logo.svg +``` +### xenserver-logo.svg + +![xenserver-logo.svg](thumbnails/xenserver-logo.svg) + +**Path:** `/img/logos/xenserver-logo.svg` + +**Usage Examples:** + +```markdown +![xenserver-logo.svg](/img/logos/xenserver-logo.svg) +``` + +```markdown +xenserver-logo.svg +``` +### governance-xen_projectstages.webp + +![governance-xen_projectstages.webp](thumbnails/governance-xen_projectstages.webp) + +**Path:** `/img/others/governance-xen_projectstages.webp` + +**Usage Examples:** + +```markdown +![governance-xen_projectstages.webp](/img/others/governance-xen_projectstages.webp) +``` + +```markdown +governance-xen_projectstages.webp +``` +### unikraft-architecture.png + +![unikraft-architecture.png](thumbnails/unikraft-architecture.png) + +**Path:** `/img/others/unikraft-architecture.png` + +**Usage Examples:** + +```markdown +![unikraft-architecture.png](/img/others/unikraft-architecture.png) +``` + +```markdown +unikraft-architecture.png +``` +### xcp-ng-badge.webp + +![xcp-ng-badge.webp](thumbnails/xcp-ng-badge.webp) + +**Path:** `/img/others/xcp-ng-badge.webp` + +**Usage Examples:** + +```markdown +![xcp-ng-badge.webp](/img/others/xcp-ng-badge.webp) +``` + +```markdown +xcp-ng-badge.webp +``` +### xcp-ng.png + +![xcp-ng.png](thumbnails/xcp-ng.png) + +**Path:** `/img/others/xcp-ng.png` + +**Usage Examples:** + +```markdown +![xcp-ng.png](/img/others/xcp-ng.png) +``` + +```markdown +xcp-ng.png +``` +### xen-progress-certification.png + +![xen-progress-certification.png](thumbnails/xen-progress-certification.png) + +**Path:** `/img/others/xen-progress-certification.png` + +**Usage Examples:** + +```markdown +![xen-progress-certification.png](/img/others/xen-progress-certification.png) +``` + +```markdown +xen-progress-certification.png +``` +### xen-team-photo-1.png + +![xen-team-photo-1.png](thumbnails/xen-team-photo-1.png) + +**Path:** `/img/others/xen-team-photo-1.png` + +**Usage Examples:** + +```markdown +![xen-team-photo-1.png](/img/others/xen-team-photo-1.png) +``` + +```markdown +xen-team-photo-1.png +``` +### xen-team-photo-2.png + +![xen-team-photo-2.png](thumbnails/xen-team-photo-2.png) + +**Path:** `/img/others/xen-team-photo-2.png` + +**Usage Examples:** + +```markdown +![xen-team-photo-2.png](/img/others/xen-team-photo-2.png) +``` + +```markdown +xen-team-photo-2.png +``` +### xen-project-2023-group-photo.png + +![xen-project-2023-group-photo.png](thumbnails/xen-project-2023-group-photo.png) + +**Path:** `/img/photos/xen-project-2023-group-photo.png` + +**Usage Examples:** + +```markdown +![xen-project-2023-group-photo.png](/img/photos/xen-project-2023-group-photo.png) +``` + +```markdown +xen-project-2023-group-photo.png +``` diff --git a/docs/images/buttons-thumb.png b/docs/images/buttons-thumb.png new file mode 100644 index 0000000..fdacaff Binary files /dev/null and b/docs/images/buttons-thumb.png differ diff --git a/docs/images/buttons-with-icons-thumb.png b/docs/images/buttons-with-icons-thumb.png new file mode 100644 index 0000000..6cb6560 Binary files /dev/null and b/docs/images/buttons-with-icons-thumb.png differ diff --git a/docs/images/buttons-with-icons.png b/docs/images/buttons-with-icons.png new file mode 100644 index 0000000..4aa5a7e Binary files /dev/null and b/docs/images/buttons-with-icons.png differ diff --git a/docs/images/buttons.png b/docs/images/buttons.png new file mode 100644 index 0000000..d8bf5e8 Binary files /dev/null and b/docs/images/buttons.png differ diff --git a/docs/images/carousel-thumb.png b/docs/images/carousel-thumb.png new file mode 100644 index 0000000..1146ff4 Binary files /dev/null and b/docs/images/carousel-thumb.png differ diff --git a/docs/images/carousel.png b/docs/images/carousel.png new file mode 100644 index 0000000..949fb36 Binary files /dev/null and b/docs/images/carousel.png differ diff --git a/docs/images/features-list-thumb.png b/docs/images/features-list-thumb.png new file mode 100644 index 0000000..cdc910e Binary files /dev/null and b/docs/images/features-list-thumb.png differ diff --git a/docs/images/features-list.png b/docs/images/features-list.png new file mode 100644 index 0000000..3e2010a Binary files /dev/null and b/docs/images/features-list.png differ diff --git a/docs/images/latest-news-thumb.png b/docs/images/latest-news-thumb.png new file mode 100644 index 0000000..fa8c060 Binary files /dev/null and b/docs/images/latest-news-thumb.png differ diff --git a/docs/images/latest-news.png b/docs/images/latest-news.png new file mode 100644 index 0000000..84ed0dd Binary files /dev/null and b/docs/images/latest-news.png differ diff --git a/docs/images/media-block--left-thumb.png b/docs/images/media-block--left-thumb.png new file mode 100644 index 0000000..4572baa Binary files /dev/null and b/docs/images/media-block--left-thumb.png differ diff --git a/docs/images/media-block--left.png b/docs/images/media-block--left.png new file mode 100644 index 0000000..9782d4c Binary files /dev/null and b/docs/images/media-block--left.png differ diff --git a/docs/images/media-block--right-thumb.png b/docs/images/media-block--right-thumb.png new file mode 100644 index 0000000..ca39c6b Binary files /dev/null and b/docs/images/media-block--right-thumb.png differ diff --git a/docs/images/media-block--right.png b/docs/images/media-block--right.png new file mode 100644 index 0000000..0d28b25 Binary files /dev/null and b/docs/images/media-block--right.png differ diff --git a/docs/images/vertical-lists-thumb.png b/docs/images/vertical-lists-thumb.png new file mode 100644 index 0000000..429c2a4 Binary files /dev/null and b/docs/images/vertical-lists-thumb.png differ diff --git a/docs/images/vertical-lists.png b/docs/images/vertical-lists.png new file mode 100644 index 0000000..617e9e1 Binary files /dev/null and b/docs/images/vertical-lists.png differ diff --git a/docs/page-advanced-editing.md b/docs/page-advanced-editing.md new file mode 100644 index 0000000..c0c8695 --- /dev/null +++ b/docs/page-advanced-editing.md @@ -0,0 +1,102 @@ +# Advanced Editing + + +## Buttons + +![Buttons](images/buttons.png) + +Buttons are used to trigger actions or navigate to other pages. There are three types of buttons available: + +### Button Types + +- **Primary Button**: Main call-to-action buttons + ```markdown + Primary button + ``` + +- **Secondary Button**: Alternative or secondary actions + ```markdown + Secondary button + ``` + +- **Tertiary Button**: Less prominent actions + ```markdown + Tertiary button + ``` + +### Icons in Buttons + +![Buttons with icons](images/buttons-with-icons.png) + +Buttons can include icons from the Font Awesome library. The convention is: + +- Internal links use the arrow-right icon: + ```markdown + + Internal link + + ``` + +- External links use the external link icon: + ```markdown + + External link + + ``` + +- Download links use the download icon: + ```markdown + + Download + + ``` + +## Links + +Links follow similar conventions to buttons for consistency across the site: + +### Link Types + +- **Internal links**: Use regular markdown syntax or HTML + ```markdown + [Internal link](/internal-page) + ``` + or + ```markdown + Internal link + ``` + +- **External links**: Include target="_blank" to open in new tab + ```markdown + + External link + + ``` + +- **Download links**: Include the download icon + ```markdown + + Download PDF + + ``` + + + +## Using Components + +To use a component, simply copy the desired component code and paste it into your Markdown file. You can customize the content and parameters according to your needs. + +## Component Customization + +Each component can be customized with different parameters. Here are some examples: + +## Best Practices + +- Use components consistently throughout the site +- Avoid overloading a page with too many components + +## Advanced Tips + +- You can nest certain components within each other +- Components can be used on any page of the site +- Some components accept Markdown inside them \ No newline at end of file diff --git a/docs/page-components.md b/docs/page-components.md new file mode 100644 index 0000000..e73680b --- /dev/null +++ b/docs/page-components.md @@ -0,0 +1,40 @@ +--- +title: "Components" +description: "Advanced editing features, particularly the use of reusable components" +--- + +# Components + +This page describes the use of reusable components. + +There are predefined components that you can insert into your pages. They help maintain visual and functional consistency throughout the site. + +Here are the main components you can use: + +Click on the component image to see the full documentation. + +### Media-block + +[![Media block component](images/media-block--left-thumb.png)](components/media-block.md) + + +### Features List + +[![Features list component](images/features-list-thumb.png)](components/feature-lists.md) + + +### Carousel + +[![Carousel component](images/carousel-thumb.png)](components/carousel.md) + + +### Latest News + +[![Latest news component](images/latest-news-thumb.png)](components/latest-news.md) + + +### Vertical Lists + +[![Vertical lists component](images/vertical-lists-thumb.png)](components/vertical-lists.md) + + diff --git a/docs/page-editing.md b/docs/page-editing.md new file mode 100644 index 0000000..8919b14 --- /dev/null +++ b/docs/page-editing.md @@ -0,0 +1,83 @@ +# Edit a page + +To modify a page on the site, follow these steps: + +## File Location + +- All site pages are located in the `content` folder +- The homepage is located in the `content/_index.md` file + +## File Format + +Pages can be written using: +- Markdown for main content +- HTML for more complex layouts +- Yaml for the front matter + +Both syntaxes can be mixed within the same file as needed. + +## Best Practices + +- Use Markdown for simple text content +- Reserve HTML for elements requiring specific formatting +- Always check how your changes look before publishing + + +## Front Matter + +The front matter is the metadata at the top of each page file. It includes information like the page title, description, and other settings. + +### Default Parameters + +Based on analysis of typical pages, the front matter usually includes: + +| Parameter | Description | +| ----------- | ------------------------------------------------------------------------------------------------------------- | +| title | The page title | +| description | A brief description of the page | +| keywords | Keywords for the page, used for SEO | +| layout | The layout type used for the page, all the pages use the layout "single" | +| date | Publication date (often used for blog posts) | +| draft | If the page is a draft, set to true, if the page is ready and published, set to false or delete the parameter | + +These parameters help structure and organize the site content while providing useful metadata for SEO and navigation. + +The parameters `title`, `description` are use for the main title and description of the page. You can see them at the top of the page. + +The parameters `title`, `description` and `keywords` are used for SEO and are used to help search engines understand the content of the page. + + +### Show a page in the menu + +By default, all the pages are shown in the menu. If you don't want to show a page in the menu, you can set the `hidden` parameter to `true`. + +The pages are grouped into folders, but their position in the menu is determined by the `menu.main` and `weight` parameters. + +To order the pages in the menu, you can set the `weight` parameter to the desired value. The lower the number, the higher up in the menu the page will be. + +Example : + + +Page downloads.md + +```yaml +title: Downloads +menus: + main: + parent: Resources + weight: 50 +``` + +Page Matrix.md + +```yaml +title: Matrix +menus: + main: + parent: Resources + weight: 70 +``` + +The page **Matrix** is after the page **Downloads** in the menu because it has a higher `weight` value. + + diff --git a/docs/readme.md b/docs/readme.md new file mode 100644 index 0000000..8941172 --- /dev/null +++ b/docs/readme.md @@ -0,0 +1,7 @@ +# Documentation + +## Links + +- [Page editing](page-editing.md) +- [Page advanced editing](page-advanced-editing.md) +- [Components](page-components.md) \ No newline at end of file diff --git a/docs/thumbnails/amd-logo.svg b/docs/thumbnails/amd-logo.svg new file mode 100644 index 0000000..ec8ea86 --- /dev/null +++ b/docs/thumbnails/amd-logo.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/docs/thumbnails/arm-logo.svg b/docs/thumbnails/arm-logo.svg new file mode 100644 index 0000000..7c4bdd6 --- /dev/null +++ b/docs/thumbnails/arm-logo.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/docs/thumbnails/aws-logo.svg b/docs/thumbnails/aws-logo.svg new file mode 100644 index 0000000..b06652a --- /dev/null +++ b/docs/thumbnails/aws-logo.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/docs/thumbnails/brainstorming-session.svg b/docs/thumbnails/brainstorming-session.svg new file mode 100644 index 0000000..3ba172a --- /dev/null +++ b/docs/thumbnails/brainstorming-session.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/docs/thumbnails/brainstorming.svg b/docs/thumbnails/brainstorming.svg new file mode 100644 index 0000000..d322b62 --- /dev/null +++ b/docs/thumbnails/brainstorming.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/docs/thumbnails/cloud.png b/docs/thumbnails/cloud.png new file mode 100644 index 0000000..4dbacd2 Binary files /dev/null and b/docs/thumbnails/cloud.png differ diff --git a/docs/thumbnails/coding.svg b/docs/thumbnails/coding.svg new file mode 100644 index 0000000..2f0b125 --- /dev/null +++ b/docs/thumbnails/coding.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/docs/thumbnails/coding2.svg b/docs/thumbnails/coding2.svg new file mode 100644 index 0000000..5cee5c3 --- /dev/null +++ b/docs/thumbnails/coding2.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/docs/thumbnails/data-analysis.svg b/docs/thumbnails/data-analysis.svg new file mode 100644 index 0000000..80563d2 --- /dev/null +++ b/docs/thumbnails/data-analysis.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/docs/thumbnails/data-analyst.svg b/docs/thumbnails/data-analyst.svg new file mode 100644 index 0000000..b673c77 --- /dev/null +++ b/docs/thumbnails/data-analyst.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/docs/thumbnails/data-center.svg b/docs/thumbnails/data-center.svg new file mode 100644 index 0000000..0573f5d --- /dev/null +++ b/docs/thumbnails/data-center.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/docs/thumbnails/data-hosting.svg b/docs/thumbnails/data-hosting.svg new file mode 100644 index 0000000..16281e5 --- /dev/null +++ b/docs/thumbnails/data-hosting.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/docs/thumbnails/data-process-with-xen-logo.svg b/docs/thumbnails/data-process-with-xen-logo.svg new file mode 100644 index 0000000..26f79f9 --- /dev/null +++ b/docs/thumbnails/data-process-with-xen-logo.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/docs/thumbnails/data-process.svg b/docs/thumbnails/data-process.svg new file mode 100644 index 0000000..6905b01 --- /dev/null +++ b/docs/thumbnails/data-process.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/docs/thumbnails/data-process2.svg b/docs/thumbnails/data-process2.svg new file mode 100644 index 0000000..eb83a11 --- /dev/null +++ b/docs/thumbnails/data-process2.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/docs/thumbnails/data-storage.svg b/docs/thumbnails/data-storage.svg new file mode 100644 index 0000000..d168068 --- /dev/null +++ b/docs/thumbnails/data-storage.svg @@ -0,0 +1,34 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/docs/thumbnails/data_and_settings.svg b/docs/thumbnails/data_and_settings.svg new file mode 100644 index 0000000..275ff0b --- /dev/null +++ b/docs/thumbnails/data_and_settings.svg @@ -0,0 +1,43 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/docs/thumbnails/epam-logo.svg b/docs/thumbnails/epam-logo.svg new file mode 100644 index 0000000..ca4a968 --- /dev/null +++ b/docs/thumbnails/epam-logo.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/docs/thumbnails/error-404.svg b/docs/thumbnails/error-404.svg new file mode 100644 index 0000000..a688e4d --- /dev/null +++ b/docs/thumbnails/error-404.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/docs/thumbnails/governance-xen_projectstages.webp b/docs/thumbnails/governance-xen_projectstages.webp new file mode 100644 index 0000000..f592c02 Binary files /dev/null and b/docs/thumbnails/governance-xen_projectstages.webp differ diff --git a/docs/thumbnails/handshake.svg b/docs/thumbnails/handshake.svg new file mode 100644 index 0000000..3e69af0 --- /dev/null +++ b/docs/thumbnails/handshake.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/docs/thumbnails/home-servers.webp b/docs/thumbnails/home-servers.webp new file mode 100644 index 0000000..63cba5b Binary files /dev/null and b/docs/thumbnails/home-servers.webp differ diff --git a/docs/thumbnails/home-shadow-screen.png b/docs/thumbnails/home-shadow-screen.png new file mode 100644 index 0000000..006710e Binary files /dev/null and b/docs/thumbnails/home-shadow-screen.png differ diff --git a/docs/thumbnails/home-wire.png b/docs/thumbnails/home-wire.png new file mode 100644 index 0000000..ff0550c Binary files /dev/null and b/docs/thumbnails/home-wire.png differ diff --git a/docs/thumbnails/honda-logo.svg b/docs/thumbnails/honda-logo.svg new file mode 100644 index 0000000..f54ece3 --- /dev/null +++ b/docs/thumbnails/honda-logo.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/docs/thumbnails/java.svg b/docs/thumbnails/java.svg new file mode 100644 index 0000000..8fb3907 --- /dev/null +++ b/docs/thumbnails/java.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/docs/thumbnails/laptop-cybersecurity.svg b/docs/thumbnails/laptop-cybersecurity.svg new file mode 100644 index 0000000..5e0b342 --- /dev/null +++ b/docs/thumbnails/laptop-cybersecurity.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/docs/thumbnails/logo-linux-foundation.svg b/docs/thumbnails/logo-linux-foundation.svg new file mode 100644 index 0000000..d0908b8 --- /dev/null +++ b/docs/thumbnails/logo-linux-foundation.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/docs/thumbnails/logo-xen-reverse.svg b/docs/thumbnails/logo-xen-reverse.svg new file mode 100644 index 0000000..9e86047 --- /dev/null +++ b/docs/thumbnails/logo-xen-reverse.svg @@ -0,0 +1,57 @@ + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/docs/thumbnails/logo-xen.svg b/docs/thumbnails/logo-xen.svg new file mode 100644 index 0000000..1788316 --- /dev/null +++ b/docs/thumbnails/logo-xen.svg @@ -0,0 +1,61 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/docs/thumbnails/new-message.svg b/docs/thumbnails/new-message.svg new file mode 100644 index 0000000..c6e48e6 --- /dev/null +++ b/docs/thumbnails/new-message.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/docs/thumbnails/screen-with-wire.svg b/docs/thumbnails/screen-with-wire.svg new file mode 100755 index 0000000..3e7efcf --- /dev/null +++ b/docs/thumbnails/screen-with-wire.svg @@ -0,0 +1,128 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/docs/thumbnails/screen-with-xen-logo.webp b/docs/thumbnails/screen-with-xen-logo.webp new file mode 100644 index 0000000..ff074df Binary files /dev/null and b/docs/thumbnails/screen-with-xen-logo.webp differ diff --git a/docs/thumbnails/security.svg b/docs/thumbnails/security.svg new file mode 100644 index 0000000..22ad245 --- /dev/null +++ b/docs/thumbnails/security.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/docs/thumbnails/small-cloud.png b/docs/thumbnails/small-cloud.png new file mode 100644 index 0000000..b5a97cf Binary files /dev/null and b/docs/thumbnails/small-cloud.png differ diff --git a/docs/thumbnails/start-up.svg b/docs/thumbnails/start-up.svg new file mode 100644 index 0000000..95dd14e --- /dev/null +++ b/docs/thumbnails/start-up.svg @@ -0,0 +1,74 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/docs/thumbnails/team-meeting.svg b/docs/thumbnails/team-meeting.svg new file mode 100644 index 0000000..46a8ae1 --- /dev/null +++ b/docs/thumbnails/team-meeting.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/docs/thumbnails/team-work.svg b/docs/thumbnails/team-work.svg new file mode 100644 index 0000000..686334f --- /dev/null +++ b/docs/thumbnails/team-work.svg @@ -0,0 +1,147 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/docs/thumbnails/timeline.svg b/docs/thumbnails/timeline.svg new file mode 100644 index 0000000..fa0732e --- /dev/null +++ b/docs/thumbnails/timeline.svg @@ -0,0 +1,47 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/docs/thumbnails/unikraft-architecture.png b/docs/thumbnails/unikraft-architecture.png new file mode 100644 index 0000000..b34750c Binary files /dev/null and b/docs/thumbnails/unikraft-architecture.png differ diff --git a/docs/thumbnails/vates-logo.svg b/docs/thumbnails/vates-logo.svg new file mode 100644 index 0000000..4dd97dc --- /dev/null +++ b/docs/thumbnails/vates-logo.svg @@ -0,0 +1,6 @@ + + + + + \ No newline at end of file diff --git a/docs/thumbnails/xcp-ng-badge.webp b/docs/thumbnails/xcp-ng-badge.webp new file mode 100644 index 0000000..38775bb Binary files /dev/null and b/docs/thumbnails/xcp-ng-badge.webp differ diff --git a/docs/thumbnails/xcp-ng.png b/docs/thumbnails/xcp-ng.png new file mode 100644 index 0000000..6970077 Binary files /dev/null and b/docs/thumbnails/xcp-ng.png differ diff --git a/docs/thumbnails/xen-panda-kungfu.png b/docs/thumbnails/xen-panda-kungfu.png new file mode 100644 index 0000000..1052130 Binary files /dev/null and b/docs/thumbnails/xen-panda-kungfu.png differ diff --git a/docs/thumbnails/xen-panda-winged.png b/docs/thumbnails/xen-panda-winged.png new file mode 100644 index 0000000..74bde44 Binary files /dev/null and b/docs/thumbnails/xen-panda-winged.png differ diff --git a/docs/thumbnails/xen-panda-zen.png b/docs/thumbnails/xen-panda-zen.png new file mode 100644 index 0000000..1824438 Binary files /dev/null and b/docs/thumbnails/xen-panda-zen.png differ diff --git a/docs/thumbnails/xen-progress-certification.png b/docs/thumbnails/xen-progress-certification.png new file mode 100644 index 0000000..3b99f52 Binary files /dev/null and b/docs/thumbnails/xen-progress-certification.png differ diff --git a/docs/thumbnails/xen-project-2023-group-photo.png b/docs/thumbnails/xen-project-2023-group-photo.png new file mode 100644 index 0000000..1795231 Binary files /dev/null and b/docs/thumbnails/xen-project-2023-group-photo.png differ diff --git a/docs/thumbnails/xen-team-photo-1.png b/docs/thumbnails/xen-team-photo-1.png new file mode 100644 index 0000000..a370fdc Binary files /dev/null and b/docs/thumbnails/xen-team-photo-1.png differ diff --git a/docs/thumbnails/xen-team-photo-2.png b/docs/thumbnails/xen-team-photo-2.png new file mode 100644 index 0000000..0ace181 Binary files /dev/null and b/docs/thumbnails/xen-team-photo-2.png differ diff --git a/docs/thumbnails/xenserver-logo.svg b/docs/thumbnails/xenserver-logo.svg new file mode 100644 index 0000000..e16cfe3 --- /dev/null +++ b/docs/thumbnails/xenserver-logo.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/hugo_stats.json b/hugo_stats.json index 21ab507..3975e0b 100644 --- a/hugo_stats.json +++ b/hugo_stats.json @@ -58,7 +58,6 @@ "box-resources", "box-resources__title", "btn", - "btn-primart", "btn-primary", "btn-secondary", "btn-tertiary", @@ -96,7 +95,6 @@ "fa-chart-line", "fa-clock-rotate-left", "fa-code", - "fa-code-fork", "fa-cogs", "fa-comments", "fa-expand", @@ -106,13 +104,11 @@ "fa-headset", "fa-lightbulb", "fa-linkedin-in", - "fa-medkit", "fa-memory", "fa-minimize", "fa-money-bill-alt", "fa-power-off", "fa-puzzle-piece", - "fa-road", "fa-search", "fa-shield-alt", "fa-shield-halved", diff --git a/package-lock.json b/package-lock.json index b43baf7..5c2ddf1 100644 --- a/package-lock.json +++ b/package-lock.json @@ -17,7 +17,8 @@ "puppeteer": "^23.7.0", "remark-gfm": "^4.0.0", "robotjs": "^0.6.0", - "sass": "^1.80.6" + "sass": "^1.80.6", + "sharp": "^0.33.2" }, "devDependencies": { "@storybook/addon-essentials": "^8.4.2", @@ -84,6 +85,16 @@ "node": ">=6.9.0" } }, + "node_modules/@emnapi/runtime": { + "version": "1.3.1", + "resolved": "https://registry.npmjs.org/@emnapi/runtime/-/runtime-1.3.1.tgz", + "integrity": "sha512-kEBmG8KyqtxJZv+ygbEim+KCGtIq1fC22Ms3S4ziXmYKm8uyoLX0MHONVKwp+9opg390VaKRNt4a7A9NwmpNhw==", + "license": "MIT", + "optional": true, + "dependencies": { + "tslib": "^2.4.0" + } + }, "node_modules/@esbuild/aix-ppc64": { "version": "0.23.1", "resolved": "https://registry.npmjs.org/@esbuild/aix-ppc64/-/aix-ppc64-0.23.1.tgz", @@ -492,6 +503,367 @@ "node": ">=18" } }, + "node_modules/@img/sharp-darwin-arm64": { + "version": "0.33.5", + "resolved": "https://registry.npmjs.org/@img/sharp-darwin-arm64/-/sharp-darwin-arm64-0.33.5.tgz", + "integrity": "sha512-UT4p+iz/2H4twwAoLCqfA9UH5pI6DggwKEGuaPy7nCVQ8ZsiY5PIcrRvD1DzuY3qYL07NtIQcWnBSY/heikIFQ==", + "cpu": [ + "arm64" + ], + "license": "Apache-2.0", + "optional": true, + "os": [ + "darwin" + ], + "engines": { + "node": "^18.17.0 || ^20.3.0 || >=21.0.0" + }, + "funding": { + "url": "https://opencollective.com/libvips" + }, + "optionalDependencies": { + "@img/sharp-libvips-darwin-arm64": "1.0.4" + } + }, + "node_modules/@img/sharp-darwin-x64": { + "version": "0.33.5", + "resolved": "https://registry.npmjs.org/@img/sharp-darwin-x64/-/sharp-darwin-x64-0.33.5.tgz", + "integrity": "sha512-fyHac4jIc1ANYGRDxtiqelIbdWkIuQaI84Mv45KvGRRxSAa7o7d1ZKAOBaYbnepLC1WqxfpimdeWfvqqSGwR2Q==", + "cpu": [ + "x64" + ], + "license": "Apache-2.0", + "optional": true, + "os": [ + "darwin" + ], + "engines": { + "node": "^18.17.0 || ^20.3.0 || >=21.0.0" + }, + "funding": { + "url": "https://opencollective.com/libvips" + }, + "optionalDependencies": { + "@img/sharp-libvips-darwin-x64": "1.0.4" + } + }, + "node_modules/@img/sharp-libvips-darwin-arm64": { + "version": "1.0.4", + "resolved": "https://registry.npmjs.org/@img/sharp-libvips-darwin-arm64/-/sharp-libvips-darwin-arm64-1.0.4.tgz", + "integrity": "sha512-XblONe153h0O2zuFfTAbQYAX2JhYmDHeWikp1LM9Hul9gVPjFY427k6dFEcOL72O01QxQsWi761svJ/ev9xEDg==", + "cpu": [ + "arm64" + ], + "license": "LGPL-3.0-or-later", + "optional": true, + "os": [ + "darwin" + ], + "funding": { + "url": "https://opencollective.com/libvips" + } + }, + "node_modules/@img/sharp-libvips-darwin-x64": { + "version": "1.0.4", + "resolved": "https://registry.npmjs.org/@img/sharp-libvips-darwin-x64/-/sharp-libvips-darwin-x64-1.0.4.tgz", + "integrity": "sha512-xnGR8YuZYfJGmWPvmlunFaWJsb9T/AO2ykoP3Fz/0X5XV2aoYBPkX6xqCQvUTKKiLddarLaxpzNe+b1hjeWHAQ==", + "cpu": [ + "x64" + ], + "license": "LGPL-3.0-or-later", + "optional": true, + "os": [ + "darwin" + ], + "funding": { + "url": "https://opencollective.com/libvips" + } + }, + "node_modules/@img/sharp-libvips-linux-arm": { + "version": "1.0.5", + "resolved": "https://registry.npmjs.org/@img/sharp-libvips-linux-arm/-/sharp-libvips-linux-arm-1.0.5.tgz", + "integrity": "sha512-gvcC4ACAOPRNATg/ov8/MnbxFDJqf/pDePbBnuBDcjsI8PssmjoKMAz4LtLaVi+OnSb5FK/yIOamqDwGmXW32g==", + "cpu": [ + "arm" + ], + "license": "LGPL-3.0-or-later", + "optional": true, + "os": [ + "linux" + ], + "funding": { + "url": "https://opencollective.com/libvips" + } + }, + "node_modules/@img/sharp-libvips-linux-arm64": { + "version": "1.0.4", + "resolved": "https://registry.npmjs.org/@img/sharp-libvips-linux-arm64/-/sharp-libvips-linux-arm64-1.0.4.tgz", + "integrity": "sha512-9B+taZ8DlyyqzZQnoeIvDVR/2F4EbMepXMc/NdVbkzsJbzkUjhXv/70GQJ7tdLA4YJgNP25zukcxpX2/SueNrA==", + "cpu": [ + "arm64" + ], + "license": "LGPL-3.0-or-later", + "optional": true, + "os": [ + "linux" + ], + "funding": { + "url": "https://opencollective.com/libvips" + } + }, + "node_modules/@img/sharp-libvips-linux-s390x": { + "version": "1.0.4", + "resolved": "https://registry.npmjs.org/@img/sharp-libvips-linux-s390x/-/sharp-libvips-linux-s390x-1.0.4.tgz", + "integrity": "sha512-u7Wz6ntiSSgGSGcjZ55im6uvTrOxSIS8/dgoVMoiGE9I6JAfU50yH5BoDlYA1tcuGS7g/QNtetJnxA6QEsCVTA==", + "cpu": [ + "s390x" + ], + "license": "LGPL-3.0-or-later", + "optional": true, + "os": [ + "linux" + ], + "funding": { + "url": "https://opencollective.com/libvips" + } + }, + "node_modules/@img/sharp-libvips-linux-x64": { + "version": "1.0.4", + "resolved": "https://registry.npmjs.org/@img/sharp-libvips-linux-x64/-/sharp-libvips-linux-x64-1.0.4.tgz", + "integrity": "sha512-MmWmQ3iPFZr0Iev+BAgVMb3ZyC4KeFc3jFxnNbEPas60e1cIfevbtuyf9nDGIzOaW9PdnDciJm+wFFaTlj5xYw==", + "cpu": [ + "x64" + ], + "license": "LGPL-3.0-or-later", + "optional": true, + "os": [ + "linux" + ], + "funding": { + "url": "https://opencollective.com/libvips" + } + }, + "node_modules/@img/sharp-libvips-linuxmusl-arm64": { + "version": "1.0.4", + "resolved": "https://registry.npmjs.org/@img/sharp-libvips-linuxmusl-arm64/-/sharp-libvips-linuxmusl-arm64-1.0.4.tgz", + "integrity": "sha512-9Ti+BbTYDcsbp4wfYib8Ctm1ilkugkA/uscUn6UXK1ldpC1JjiXbLfFZtRlBhjPZ5o1NCLiDbg8fhUPKStHoTA==", + "cpu": [ + "arm64" + ], + "license": "LGPL-3.0-or-later", + "optional": true, + "os": [ + "linux" + ], + "funding": { + "url": "https://opencollective.com/libvips" + } + }, + "node_modules/@img/sharp-libvips-linuxmusl-x64": { + "version": "1.0.4", + "resolved": "https://registry.npmjs.org/@img/sharp-libvips-linuxmusl-x64/-/sharp-libvips-linuxmusl-x64-1.0.4.tgz", + "integrity": "sha512-viYN1KX9m+/hGkJtvYYp+CCLgnJXwiQB39damAO7WMdKWlIhmYTfHjwSbQeUK/20vY154mwezd9HflVFM1wVSw==", + "cpu": [ + "x64" + ], + "license": "LGPL-3.0-or-later", + "optional": true, + "os": [ + "linux" + ], + "funding": { + "url": "https://opencollective.com/libvips" + } + }, + "node_modules/@img/sharp-linux-arm": { + "version": "0.33.5", + "resolved": "https://registry.npmjs.org/@img/sharp-linux-arm/-/sharp-linux-arm-0.33.5.tgz", + "integrity": "sha512-JTS1eldqZbJxjvKaAkxhZmBqPRGmxgu+qFKSInv8moZ2AmT5Yib3EQ1c6gp493HvrvV8QgdOXdyaIBrhvFhBMQ==", + "cpu": [ + "arm" + ], + "license": "Apache-2.0", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": "^18.17.0 || ^20.3.0 || >=21.0.0" + }, + "funding": { + "url": "https://opencollective.com/libvips" + }, + "optionalDependencies": { + "@img/sharp-libvips-linux-arm": "1.0.5" + } + }, + "node_modules/@img/sharp-linux-arm64": { + "version": "0.33.5", + "resolved": "https://registry.npmjs.org/@img/sharp-linux-arm64/-/sharp-linux-arm64-0.33.5.tgz", + "integrity": "sha512-JMVv+AMRyGOHtO1RFBiJy/MBsgz0x4AWrT6QoEVVTyh1E39TrCUpTRI7mx9VksGX4awWASxqCYLCV4wBZHAYxA==", + "cpu": [ + "arm64" + ], + "license": "Apache-2.0", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": "^18.17.0 || ^20.3.0 || >=21.0.0" + }, + "funding": { + "url": "https://opencollective.com/libvips" + }, + "optionalDependencies": { + "@img/sharp-libvips-linux-arm64": "1.0.4" + } + }, + "node_modules/@img/sharp-linux-s390x": { + "version": "0.33.5", + "resolved": "https://registry.npmjs.org/@img/sharp-linux-s390x/-/sharp-linux-s390x-0.33.5.tgz", + "integrity": "sha512-y/5PCd+mP4CA/sPDKl2961b+C9d+vPAveS33s6Z3zfASk2j5upL6fXVPZi7ztePZ5CuH+1kW8JtvxgbuXHRa4Q==", + "cpu": [ + "s390x" + ], + "license": "Apache-2.0", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": "^18.17.0 || ^20.3.0 || >=21.0.0" + }, + "funding": { + "url": "https://opencollective.com/libvips" + }, + "optionalDependencies": { + "@img/sharp-libvips-linux-s390x": "1.0.4" + } + }, + "node_modules/@img/sharp-linux-x64": { + "version": "0.33.5", + "resolved": "https://registry.npmjs.org/@img/sharp-linux-x64/-/sharp-linux-x64-0.33.5.tgz", + "integrity": "sha512-opC+Ok5pRNAzuvq1AG0ar+1owsu842/Ab+4qvU879ippJBHvyY5n2mxF1izXqkPYlGuP/M556uh53jRLJmzTWA==", + "cpu": [ + "x64" + ], + "license": "Apache-2.0", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": "^18.17.0 || ^20.3.0 || >=21.0.0" + }, + "funding": { + "url": "https://opencollective.com/libvips" + }, + "optionalDependencies": { + "@img/sharp-libvips-linux-x64": "1.0.4" + } + }, + "node_modules/@img/sharp-linuxmusl-arm64": { + "version": "0.33.5", + "resolved": "https://registry.npmjs.org/@img/sharp-linuxmusl-arm64/-/sharp-linuxmusl-arm64-0.33.5.tgz", + "integrity": "sha512-XrHMZwGQGvJg2V/oRSUfSAfjfPxO+4DkiRh6p2AFjLQztWUuY/o8Mq0eMQVIY7HJ1CDQUJlxGGZRw1a5bqmd1g==", + "cpu": [ + "arm64" + ], + "license": "Apache-2.0", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": "^18.17.0 || ^20.3.0 || >=21.0.0" + }, + "funding": { + "url": "https://opencollective.com/libvips" + }, + "optionalDependencies": { + "@img/sharp-libvips-linuxmusl-arm64": "1.0.4" + } + }, + "node_modules/@img/sharp-linuxmusl-x64": { + "version": "0.33.5", + "resolved": "https://registry.npmjs.org/@img/sharp-linuxmusl-x64/-/sharp-linuxmusl-x64-0.33.5.tgz", + "integrity": "sha512-WT+d/cgqKkkKySYmqoZ8y3pxx7lx9vVejxW/W4DOFMYVSkErR+w7mf2u8m/y4+xHe7yY9DAXQMWQhpnMuFfScw==", + "cpu": [ + "x64" + ], + "license": "Apache-2.0", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": "^18.17.0 || ^20.3.0 || >=21.0.0" + }, + "funding": { + "url": "https://opencollective.com/libvips" + }, + "optionalDependencies": { + "@img/sharp-libvips-linuxmusl-x64": "1.0.4" + } + }, + "node_modules/@img/sharp-wasm32": { + "version": "0.33.5", + "resolved": "https://registry.npmjs.org/@img/sharp-wasm32/-/sharp-wasm32-0.33.5.tgz", + "integrity": "sha512-ykUW4LVGaMcU9lu9thv85CbRMAwfeadCJHRsg2GmeRa/cJxsVY9Rbd57JcMxBkKHag5U/x7TSBpScF4U8ElVzg==", + "cpu": [ + "wasm32" + ], + "license": "Apache-2.0 AND LGPL-3.0-or-later AND MIT", + "optional": true, + "dependencies": { + "@emnapi/runtime": "^1.2.0" + }, + "engines": { + "node": "^18.17.0 || ^20.3.0 || >=21.0.0" + }, + "funding": { + "url": "https://opencollective.com/libvips" + } + }, + "node_modules/@img/sharp-win32-ia32": { + "version": "0.33.5", + "resolved": "https://registry.npmjs.org/@img/sharp-win32-ia32/-/sharp-win32-ia32-0.33.5.tgz", + "integrity": "sha512-T36PblLaTwuVJ/zw/LaH0PdZkRz5rd3SmMHX8GSmR7vtNSP5Z6bQkExdSK7xGWyxLw4sUknBuugTelgw2faBbQ==", + "cpu": [ + "ia32" + ], + "license": "Apache-2.0 AND LGPL-3.0-or-later", + "optional": true, + "os": [ + "win32" + ], + "engines": { + "node": "^18.17.0 || ^20.3.0 || >=21.0.0" + }, + "funding": { + "url": "https://opencollective.com/libvips" + } + }, + "node_modules/@img/sharp-win32-x64": { + "version": "0.33.5", + "resolved": "https://registry.npmjs.org/@img/sharp-win32-x64/-/sharp-win32-x64-0.33.5.tgz", + "integrity": "sha512-MpY/o8/8kj+EcnxwvrP4aTJSWw/aZ7JIGR4aBeZkZw5B7/Jn+tY9/VNwtcoGmdT7GfggGIU4kygOMSbYnOrAbg==", + "cpu": [ + "x64" + ], + "license": "Apache-2.0 AND LGPL-3.0-or-later", + "optional": true, + "os": [ + "win32" + ], + "engines": { + "node": "^18.17.0 || ^20.3.0 || >=21.0.0" + }, + "funding": { + "url": "https://opencollective.com/libvips" + } + }, "node_modules/@jridgewell/gen-mapping": { "version": "0.3.5", "license": "MIT", @@ -2738,6 +3110,19 @@ "node": ">=0.10.0" } }, + "node_modules/color": { + "version": "4.2.3", + "resolved": "https://registry.npmjs.org/color/-/color-4.2.3.tgz", + "integrity": "sha512-1rXeuUUiGGrykh+CeBdu5Ie7OJwinCgQY0bc7GCRxy5xVHy+moaqkpL/jqQq0MtQOeYcrqEz4abc5f0KtU7W4A==", + "license": "MIT", + "dependencies": { + "color-convert": "^2.0.1", + "color-string": "^1.9.0" + }, + "engines": { + "node": ">=12.5.0" + } + }, "node_modules/color-convert": { "version": "2.0.1", "license": "MIT", @@ -2752,6 +3137,16 @@ "version": "1.1.4", "license": "MIT" }, + "node_modules/color-string": { + "version": "1.9.1", + "resolved": "https://registry.npmjs.org/color-string/-/color-string-1.9.1.tgz", + "integrity": "sha512-shrVawQFojnZv6xM40anx4CkoDP+fZsw/ZerEMsW/pyzsRbElpsL/DBVW7q3ExxwusdNXI3lXpuhEZkzs8p5Eg==", + "license": "MIT", + "dependencies": { + "color-name": "^1.0.0", + "simple-swizzle": "^0.2.2" + } + }, "node_modules/combined-stream": { "version": "1.0.8", "resolved": "https://registry.npmjs.org/combined-stream/-/combined-stream-1.0.8.tgz", @@ -6144,6 +6539,54 @@ "node": ">= 0.4" } }, + "node_modules/sharp": { + "version": "0.33.5", + "resolved": "https://registry.npmjs.org/sharp/-/sharp-0.33.5.tgz", + "integrity": "sha512-haPVm1EkS9pgvHrQ/F3Xy+hgcuMV0Wm9vfIBSiwZ05k+xgb0PkBQpGsAA/oWdDobNaZTH5ppvHtzCFbnSEwHVw==", + "hasInstallScript": true, + "license": "Apache-2.0", + "dependencies": { + "color": "^4.2.3", + "detect-libc": "^2.0.3", + "semver": "^7.6.3" + }, + "engines": { + "node": "^18.17.0 || ^20.3.0 || >=21.0.0" + }, + "funding": { + "url": "https://opencollective.com/libvips" + }, + "optionalDependencies": { + "@img/sharp-darwin-arm64": "0.33.5", + "@img/sharp-darwin-x64": "0.33.5", + "@img/sharp-libvips-darwin-arm64": "1.0.4", + "@img/sharp-libvips-darwin-x64": "1.0.4", + "@img/sharp-libvips-linux-arm": "1.0.5", + "@img/sharp-libvips-linux-arm64": "1.0.4", + "@img/sharp-libvips-linux-s390x": "1.0.4", + "@img/sharp-libvips-linux-x64": "1.0.4", + "@img/sharp-libvips-linuxmusl-arm64": "1.0.4", + "@img/sharp-libvips-linuxmusl-x64": "1.0.4", + "@img/sharp-linux-arm": "0.33.5", + "@img/sharp-linux-arm64": "0.33.5", + "@img/sharp-linux-s390x": "0.33.5", + "@img/sharp-linux-x64": "0.33.5", + "@img/sharp-linuxmusl-arm64": "0.33.5", + "@img/sharp-linuxmusl-x64": "0.33.5", + "@img/sharp-wasm32": "0.33.5", + "@img/sharp-win32-ia32": "0.33.5", + "@img/sharp-win32-x64": "0.33.5" + } + }, + "node_modules/sharp/node_modules/detect-libc": { + "version": "2.0.3", + "resolved": "https://registry.npmjs.org/detect-libc/-/detect-libc-2.0.3.tgz", + "integrity": "sha512-bwy0MGW55bG41VqxxypOsdSdGqLwXPI/focwgTYCFMbdUiBAxLg9CFzG08sz2aqzknwiX7Hkl0bQENjg8iLByw==", + "license": "Apache-2.0", + "engines": { + "node": ">=8" + } + }, "node_modules/signal-exit": { "version": "3.0.7", "resolved": "https://registry.npmjs.org/signal-exit/-/signal-exit-3.0.7.tgz", @@ -6181,6 +6624,21 @@ "simple-concat": "^1.0.0" } }, + "node_modules/simple-swizzle": { + "version": "0.2.2", + "resolved": "https://registry.npmjs.org/simple-swizzle/-/simple-swizzle-0.2.2.tgz", + "integrity": "sha512-JA//kQgZtbuY83m+xT+tXJkmJncGMTFT+C+g2h2R9uxkYIrE2yy9sgmcLhCnw57/WSD+Eh3J97FPEDFnbXnDUg==", + "license": "MIT", + "dependencies": { + "is-arrayish": "^0.3.1" + } + }, + "node_modules/simple-swizzle/node_modules/is-arrayish": { + "version": "0.3.2", + "resolved": "https://registry.npmjs.org/is-arrayish/-/is-arrayish-0.3.2.tgz", + "integrity": "sha512-eVRqCvVlZbuw3GrM63ovNSNAeA1K16kaR/LRY/92w0zxQ5/1YzwblUX652i4Xs9RwAGjW9d9y6X88t8OaAJfWQ==", + "license": "MIT" + }, "node_modules/smart-buffer": { "version": "4.2.0", "resolved": "https://registry.npmjs.org/smart-buffer/-/smart-buffer-4.2.0.tgz", diff --git a/package.json b/package.json index adcc2f2..3241230 100644 --- a/package.json +++ b/package.json @@ -12,7 +12,8 @@ "storybook": "storybook dev -p 6006", "build-storybook": "storybook build", "storybook-tasks": "node scripts/storybook-tasks.js", - "sb-images": "node scripts/storytasks/storybook-images.js" + "sb-images": "node scripts/storytasks/storybook-images.js", + "doc": "node scripts/documentation/generate-thumbnails.js && node scripts/documentation/images.js" }, "author": "", "license": "ISC", @@ -40,7 +41,8 @@ "puppeteer": "^23.7.0", "remark-gfm": "^4.0.0", "robotjs": "^0.6.0", - "sass": "^1.80.6" + "sass": "^1.80.6", + "sharp": "^0.33.2" }, "volta": { "node": "22.7.0" diff --git a/scripts/documentation/generate-thumbnails.js b/scripts/documentation/generate-thumbnails.js new file mode 100644 index 0000000..22c20bc --- /dev/null +++ b/scripts/documentation/generate-thumbnails.js @@ -0,0 +1,55 @@ +import sharp from "sharp"; +import { promises as fs } from "fs"; +import path from "path"; +import { fileURLToPath } from "url"; + +// Get the correct path in ES modules mode +const __filename = fileURLToPath(import.meta.url); +const __dirname = path.dirname(__filename); + +async function generateThumbnails() { + const imagesDir = path.join(process.cwd(), "docs/images"); + + try { + // Read all files in the directory + const files = await fs.readdir(imagesDir); + + // Filter to keep only images that are not already thumbnails + const imageFiles = files.filter((file) => { + const ext = path.extname(file).toLowerCase(); + return [".jpg", ".jpeg", ".png", ".webp", ".avif"].includes(ext) && !file.includes("-thumb."); + }); + + // Process each image + for (const file of imageFiles) { + const inputPath = path.join(imagesDir, file); + const ext = path.extname(file); + const basename = path.basename(file, ext); + const outputPath = path.join(imagesDir, `${basename}-thumb${ext}`); + + // Check if thumbnail already exists + try { + await fs.access(outputPath); + console.log(`Thumbnail already exists for ${file}`); + continue; + } catch { + // Thumbnail doesn't exist, create it + await sharp(inputPath) + .resize({ + height: 320, + fit: "contain", + withoutEnlargement: true, + }) + .toFile(outputPath); + + console.log(`Thumbnail created for ${file}`); + } + } + } catch (error) { + console.error("Error generating thumbnails:", error); + process.exit(1); + } +} + +// Direct call of the async function +generateThumbnails(); diff --git a/scripts/documentation/images.js b/scripts/documentation/images.js new file mode 100644 index 0000000..2434ed3 --- /dev/null +++ b/scripts/documentation/images.js @@ -0,0 +1,79 @@ +import { promises as fs } from "fs"; +import path from "path"; +import sharp from "sharp"; + +const IMAGES_DIR = "static/img"; +const DOCS_FILE = "docs/images.md"; +const THUMBNAIL_SIZE = 320; + +async function getAllImageFiles(dir) { + const entries = await fs.readdir(dir, { withFileTypes: true }); + const files = await Promise.all( + entries.map(async (entry) => { + const fullPath = path.join(dir, entry.name); + if (entry.isDirectory()) { + return getAllImageFiles(fullPath); + } else if (/\.(jpg|jpeg|png|gif|svg|webp)$/i.test(entry.name)) { + return fullPath; + } + return []; + }), + ); + return files.flat(); +} + +async function generateImageDoc() { + try { + // Read all files recursively from the images directory + const imageFiles = await getAllImageFiles(IMAGES_DIR); + + let markdown = "# Images\n\n"; + markdown += "This document lists all available images in the project with their paths and usage examples.\n\n"; + markdown += "## List of images\n\n"; + + for (const filePath of imageFiles) { + const file = path.basename(filePath); + const relativePath = filePath.replace(/^static\//, "/"); + + // Generate thumbnail + const thumbnailPath = path.join("docs", "thumbnails", file); + await fs.mkdir(path.dirname(thumbnailPath), { recursive: true }); + + if (!file.endsWith(".svg")) { + await sharp(filePath) + .resize(THUMBNAIL_SIZE, THUMBNAIL_SIZE, { + fit: "inside", + withoutEnlargement: true, + }) + .toFile(thumbnailPath); + } else { + // Pour les SVGs, lire le contenu, ajouter les dimensions et sauvegarder + const svgContent = await fs.readFile(filePath, "utf8"); + const modifiedSvg = svgContent.replace(/`, + "```\n", + ].join("\n"); + } + + // Write the markdown file + await fs.writeFile(DOCS_FILE, markdown, "utf8"); + console.log("Image documentation generated successfully!"); + } catch (error) { + console.error("Error generating image documentation:", error); + } +} + +generateImageDoc();