| Commit message (Collapse) | Author | Age | Files | Lines |
| |
|
|
|
|
|
|
|
|
|
| |
Since `sideEffects` has been added to activate tree shakings, the
styles are imported in the wrong order in production build. There is an
open issue (again) on Next.js repo. I'm not sure it will be fixed soon
so in the meantime I had to increase the specifity of some selectors
to avoid broken styles.
I also fixed two minor layout errors:
* CV page widgets should use headings of level 2
* Homepage should wrap the cards in list items
|
| |
|
|
|
|
|
|
|
|
|
|
|
| |
* make sure url are absolutes
* nest breadcrumb schema in webpage schema
* trim HTML tags from content/description
* use a regular script instead of next/script (with the latter the
schema is not updated on route change)
* place the script in document head
* add keywords, wordCount and readingTime keys in BlogPosting schema
* fix breadcrumbs in search page (without query)
* add tests (a `MatchInlineSnapshot` will be better but Prettier 3 is
not supported yet)
|
| |
|
|
|
|
|
| |
* use next/router to get the slug instead of using props
* handle cases where the current page title is not provided
* update JSON-LD schema to match the example in documentation
* add tests
|
| |
|
|
|
|
|
|
|
| |
* move custom homepage components that does not require props to the
MDX file (links should not need to be translated here but where they
are defined)
* move SEO title and meta desc to MDX file
* make Page component the wrapper instead of using a React fragment
* fix MDX module types
|
| |
|
|
|
|
|
|
|
|
|
|
| |
The Typescript mapped types was useful for autocompletion in fetchers
but their are harder to maintain. I think it's better to keep each
query close to its fetcher to have a better understanding of the
fetched data. So I:
* colocate queries with their own fetcher
* colocate mutations with their own mutator
* remove Typescript mapped types for queries and mutations
* move data convertors inside graphql services
* rename most of data types and fetchers
|
| |
|
|
|
|
|
|
| |
* replace Section component by a generic one (other components should
be able to use it)
* add a PageSection component
* add `hasSections` prop to Page component
* remove sectioned-page template
|
| |
|
|
|
|
|
|
|
| |
It is easier to read and to maintain this way. The `items` prop was not
useful since we are not manipulating the items. Changes:
* extract GridItem component from Grid component
* replace `items` prop of type Array<ReactNode> with `children` prop of
type ReactNode
* remove GridItem styles
|
| |
|
|
|
|
|
| |
Instead of repeating the overriding on each pages, we should define
it in one place and reuse it in pages.
By default it is not possible to override native HTML tags with MDX
so I added a plugin in next config to allow it.
|
| |
|
|
|
|
|
|
|
| |
* split pages in smaller components (it is both easier to maintain and
more readable, we avoid the use of fragments in pages directory)
* extract breadcrumbs from article tag (the navigation is not related
to the page contents)
* remove useReadingTime hook
* remove layout options except `isHome`
|
| |
|
|
|
|
| |
* replace `items` prop on MetaList with `children` prop: it was too
restrictive and the global options was not really useful. It is better
too give control to the consumers.
|
| |
|
|
|
|
|
| |
It does not make sense to re-export an existing object through a hook.
On some pages both the hook and the object was imported...
It is better to use the CONFIG (previously settings) object directly
and by doing it we avoid potential errors because of conditional hooks.
|
| |
|
|
|
| |
* merge Columns, Gallery and CardsList into Grid component
* add more options to control the grid
|
| |
|
|
|
|
|
|
|
|
|
|
|
| |
* make the component more generic
* merge `<Summary />` and `<Comment />` styles into card component
to avoid repeating the same structure
* remove most of the props to use composition
However the CSS is a bit complex because of the two variants...
Also, the component should be refactored when the CSS pseudo-class
`:has` has enough support: the provider and the `cover` and `meta`
props should be removed.
|
| |
|
|
|
|
| |
Instead of using helpers functions to format the date each time we need
to use a time element, it makes more sense to create a new component
dedicated to this task.
|
| |
|
|
|
|
| |
It removes items complexity by allowing consumers to use any label/value
association. Translations should also be defined by the consumer.
Each item can now be configured separately (borders, layout...).
|
| |
|
|
|
|
|
|
| |
The styles applied to ResponsiveImage are related to the figure and
figcaption elements. Those elements could be use with other contents
than images. So I extracted them in a Figure component. The
ResponsiveImage component is no longer useful: the consumer should use
the Image component from `next` and wrap it in a link if needed.
|
| |
|
|
|
|
|
|
|
| |
* change `items` prop to children
* replace `kind` prop with `isHierarchical`, `isOrdered` & `isInline` props
* add `hideMarker` prop
* add `spacing` prop to control item spacing
* move lists styles to Sass placeholders to avoid repeats because of
headless WordPress
|
| |
|
|
|
| |
Sizes are also predefined and can be set using the `size` prop,
so the consumers should no longer adjust the size in CSS.
|
| |
|
|
|
|
|
|
|
| |
* 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
|
| |
|
|
|
|
| |
* Make it compliant with ESlint rules
* Remove mandatory heading, it now depends on the consumer
* Change defaults for hasBorder and variant
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
| |
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
|
| |
|
|
|
|
|
|
| |
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.
|
| |
|
|
|
|
| |
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.
|
| |
|
|
|
| |
* MDX type has changed so some components props had to be updated
* Since Storybook now supports TS, I renamed the main/preview files
|
| |
|
|
|
|
| |
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.
|
| | |
|
| | |
|
| | |
|
| |
|
|
|
| |
It prevents to rerender the common components between pages (header,
footer...).
|
| | |
|
| | |
|
| |
|
|
|
|
| |
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.
|
| | |
|
| |
|
|
|
| |
Since I'm using new components, I will also rewrite the GraphQL queries
so it is easier to start from scratch.
|
| |
|
|
|
| |
I'm not able to configure SWC plugins in Next.js so to make it works,
all translation must have an id.
|
| | |
|
| |
|
|
|
|
|
|
| |
* refactor: replace script tags with next/script
Since next.js v12.1.0 some warnings was displayed because I was using
some script tags.
* build(deps): bump next-themes to v0.1.1
|
| | |
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Squashed commit of the following:
commit 49c1b3b1556a0eb91c429a961fedd2bded8ffd47
Author: Armand Philippot <git@armandphilippot.com>
Date: Wed Feb 16 15:17:52 2022 +0100
chore: add headline field to blogPosting schema
commit 42214c6f032cc899ec252a9387be35dcad738546
Author: Armand Philippot <git@armandphilippot.com>
Date: Wed Feb 16 15:09:11 2022 +0100
chore: update the searchAction markup and add query-input
Google was complaining about "query-input" which is not in Schema.org
representation. So I added it.
commit 5f29226d937cbdcd262df2793f1588435d850f02
Author: Armand Philippot <git@armandphilippot.com>
Date: Wed Feb 16 14:32:14 2022 +0100
chore: remove breadcrumb from homepage
The breadcrumb is not displayed on the homepage, so the breadcrumb
field should not appear inside Schema markup.
|
| |
|
|
| |
This way, even whithout JS, user can see the latest posts.
|
| | |
|
| | |
|
| | |
|
| |
|
|
|
|
|
|
| |
The previous method was not working so I tried a different approach.
Translation is loaded but I'm still getting warnings:
* Plurals for locale undefined aren't loaded
* Text content did not match
I can't figure how to fix them...
|
| | |
|
| |
|
|
|
| |
I will need the country code, so I think it makes more sense to gather
them inside the same property.
|
| |
|
|
| |
I also added the featured image on single article.
|
| | |
|
| | |
|
| | |
|