aboutsummaryrefslogtreecommitdiffstats
path: root/src/components/templates
Commit message (Collapse)AuthorAgeFilesLines
* refactor(components): rewrite Branding componentArmand Philippot2023-11-112-16/+119
| | | | | | The component should only be responsible of the layout for the logo, the name and the optional baseline. Also, the homepage url could be different from `/` so the consumer should give the right url.
* feat(components): add a generic Flip componentArmand Philippot2023-11-111-3/+28
| | | | | | The flipping animation is used at several places so it makes sense to use a single component to handle the animation. It will avoid styles duplication.
* refactor(components): merge HeadingButton and Widget componentsArmand Philippot2023-11-112-17/+14
| | | | | | The HeadingButton component was only used inside Widget component and it is not very useful on its own so I merge the two components in a new Collapsible component.
* refactor(components): rewrite BackToTop componentArmand Philippot2023-11-111-1/+1
| | | | | * replace `link` prop with `anchor` prop * add a `label` prop to let consumer handle the accessible name
* refactor(components): rewrite Notice componentArmand Philippot2023-11-111-10/+6
| | | | * Rename message prop to children prop and set ReactNode as type
* refactor(components): remove Column and NoScript from atomsArmand Philippot2023-11-112-3/+17
| | | | | | | * Column is a simple div meant to be used inside Columns component so they should live together. * NoScript is only used in Layout component and its name does not make sense since it needs to be used inside a `noscript` element.
* feat(components): replace icons with a generic Icon componentArmand Philippot2023-10-241-17/+12
| | | | | Sizes are also predefined and can be set using the `size` prop, so the consumers should no longer adjust the size in CSS.
* feat(components): add Article, Aside, Footer, Header, Main & NavArmand Philippot2023-10-241-9/+9
| | | | | Some components have been renamed to be able to create Footer, Header and Nav.
* refactor(components): rewrite Heading componentArmand Philippot2023-10-242-74/+115
| | | | | | | | | * remove `alignment` and `withMargin` props (consumer should handle that) * move styles to Sass placeholders to avoid repeats with headings coming from WordPress * refactor some other components that depend on Heading to avoid ESlint errors
* refactor(components): rewrite Section componentArmand Philippot2023-10-244-64/+76
| | | | | | * Make it compliant with ESlint rules * Remove mandatory heading, it now depends on the consumer * Change defaults for hasBorder and variant
* refactor(components): rewrite Button and ButtonLink componentsArmand Philippot2023-10-242-12/+10
| | | | | | | | | | | | | | Both: * move styles to Sass placeholders Button: * add `isPressed` prop to Button * add `isLoading` prop to Button (to differentiate state from disabled) ButtonLink: * replace `external` prop with `isExternal` prop * replace `href` prop with `to` prop
* refactor(routes): replace hardcoded routes with constantsArmand Philippot2023-10-241-23/+37
| | | | | | | | It makes it easier to change a route if needed and it avoid typo mistakes. I also refactored a bit the concerned files to be complient with the new ESlint config. However, I should rewrite the pages to reduce the number of statements.
* build: convert project to esmArmand Philippot2023-10-243-1/+4
|
* refactor(components): rewrite form componentsArmand Philippot2023-10-241-7/+7
|
* refactor: use named export for everything except pagesArmand Philippot2023-09-2013-77/+75
| | | | | | Next expect a default export for pages so only those components should use default exports. Everything else should use named exports to reduce the number of import statements.
* refactor(build): replace paths aliases with relative pathsArmand Philippot2023-09-199-54/+54
| | | | | | Using paths aliases starting with "@" can be confusing and can lead to conflict with existings modules. I prefer to use relative paths to avoid extra configuration in tools because of these aliases.
* refactor(types): move and rename GraphQL typesArmand Philippot2022-08-201-2/+2
| | | | | | | The api file in services was not really readable. So I move the types and I also rewrite a little the fetch function. I also rename most of the type to avoid conflict with preexisting types (like Node) and to keep consistency.
* chore: add aria hidden attribute to SVG iconsArmand Philippot2022-06-071-5/+25
|
* test(unit): fix Jest errors due to images importArmand Philippot2022-06-031-1/+1
| | | | | I mocked some SVG files and moves the branding photo to public directory. It is more a workaround than a real fix but it works so...
* test: install and configure cypressArmand Philippot2022-06-023-3/+3
| | | | I also configure Jest to avoid conflicts between Cypress and Jest.
* fix: reset focus to top of the page on route changeArmand Philippot2022-05-251-2/+8
|
* build(deps): bump all dependenciesArmand Philippot2022-05-252-5/+5
| | | | | | | I moved the website picture from useSettings to the layout component since it is only used here. This reduce the number of Jest errors. However, there's still some issues with some images import...
* chore: add a search form when posts list prints no resultsArmand Philippot2022-05-241-1/+6
|
* refactor: reduce the number of data transformationArmand Philippot2022-05-232-130/+4
|
* fix: render all images unoptimized in StorybookArmand Philippot2022-05-222-18/+6
| | | | | | There is a bug with next/image and Storybook. I was manually adding `unoptimized` to images. Instead we can use a workaround by adding an extra config in Storybook `preview.js` file.
* fix(comments): allow a depth of 2 instead of 1Armand Philippot2022-05-211-1/+1
| | | | | If I keep 1, some older comments are not displayed because the comments tree was deeper.
* chore: complete Storybook storiesArmand Philippot2022-05-212-0/+50
|
* refactor: rewrite Prism hooks and providersArmand Philippot2022-05-191-4/+1
| | | | | It avoid some hydratation errors on project pages (not in article however) and the hooks are now reusable.
* chore: fix minor styles/typescript issues introduced during refactoringArmand Philippot2022-05-181-0/+1
|
* chore: handle settings changeArmand Philippot2022-05-182-4/+9
|
* chore: use persistent layoutArmand Philippot2022-05-178-77/+105
| | | | | It prevents to rerender the common components between pages (header, footer...).
* chore: adjust articles stylesArmand Philippot2022-05-172-33/+61
| | | | | * change animation on article card hover * change comments section alignment
* chore: listen scroll to hide/show back to top buttonArmand Philippot2022-05-172-2/+31
|
* chore: adjust and complete missing stylesArmand Philippot2022-05-163-5/+20
| | | | | | * add logo to topics pages and links * add Prism styles to articles * and a few other adjustements
* refactor: use custom hook for breadcrumb items and schemaArmand Philippot2022-05-169-48/+149
|
* chore: improve accessibilityArmand Philippot2022-05-151-2/+16
|
* chore: add Article pagesArmand Philippot2022-05-152-11/+90
|
* chore: add Search pageArmand Philippot2022-05-151-1/+2
|
* chore: add the Blog index pageArmand Philippot2022-05-131-37/+25
|
* chore: add Project single pagesArmand Philippot2022-05-131-0/+5
|
* refactor: rewrite DescriptionList and Meta componentsArmand Philippot2022-05-092-71/+50
| | | | | | The meta can have different layout. The previous implementation was not enough to easily change the layout. Also, I prefer to restrict the meta types and it prevents me to repeat myself for the labels.
* chore: add homepageArmand Philippot2022-05-033-29/+97
|
* chore: add a PageLayout componentArmand Philippot2022-04-255-1/+861
|
* chore: add a SectionedLayout componentArmand Philippot2022-04-223-0/+145
|
* chore: add a Layout componentArmand Philippot2022-04-224-0/+251
It defines the different components used by all other layouts.