Skip to content

Commit

Permalink
Docs: Change relative path to absolute path in md #DS-1364
Browse files Browse the repository at this point in the history
  • Loading branch information
curdaj committed Jul 9, 2024
1 parent e7eed31 commit ebd2b3f
Show file tree
Hide file tree
Showing 14 changed files with 87 additions and 48 deletions.
2 changes: 1 addition & 1 deletion CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ Here are some tips how to make your contributing efforts efficient and eventuall

This project uses `makefile` for managing various chores, like dependency installation, testing, linting etc. Make sure you run `make` right after you clone the repository - it will set you up with everything needed to get started. Once you are done with that, have a look at what commands (targets) are available for you to run using `make` - `make install` etc.

## [Decisions](./docs/decisions/README.md)
## [Decisions](https://github.com/lmc-eu/spirit-design-system/blob/main/docs/decisions/README.md)

The reasoning behind various decisions made for the Spirit Design System. A good historical record.

Expand Down
4 changes: 3 additions & 1 deletion DEPRECATIONS-v3.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,10 @@ Introducing deprecations and feature flags to be removed in the version 3 lists.

## spirit-web-twig v3

- [Deprecations](./packages/web-twig/DEPRECATIONS-v3.md)
- [Deprecations][web-twig-deprecations]

---

Please refer back to this list or reach out to our team if you encounter any issues during migration.

[web-twig-deprecations]: https://github.com/lmc-eu/spirit-design-system/blob/main/packages/web-twig/DEPRECATIONS.md
4 changes: 3 additions & 1 deletion MIGRATION.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
# Migration Guides

Check the [`docs/migrations`](./docs/migrations/) directory to find migration guides for new versions of all packages.
Check the [`docs/migrations`][docs-migrations] directory to find migration guides for new versions of all packages.

[docs-migrations]: https://github.com/lmc-eu/spirit-design-system/blob/main/docs/migrations/README.md
57 changes: 38 additions & 19 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,9 @@

### Spirit Design System

[![Maintained with Lerna](https://img.shields.io/badge/maintained%20with-lerna-cc00ff.svg)](https://lerna.js.org)
[![Code Quality Checks](https://github.com/lmc-eu/spirit-design-system/actions/workflows/test.yaml/badge.svg?branch=main)](https://github.com/lmc-eu/spirit-design-system/actions)
[![Coverage Status](https://coveralls.io/repos/github/lmc-eu/spirit-design-system/badge.svg?branch=main)](https://coveralls.io/github/lmc-eu/spirit-design-system?branch=main)
[![Maintained with Lerna][lerna-svg]][lerna]
[![Code Quality Checks][code-quality-checks-svg]][code-quality-checks]
[![Coverage Status][coverage-status-svg]][coverage-status]

Spirit is an open-source design system developed by [Alma Career (formerly LMC)][alma-career].

Expand All @@ -17,25 +17,25 @@ See individual [packages](#packages) to learn how to get started.

## Packages

| Package name | Description | Version |
| ---------------------------------------------------------------- | ------------------------------------------------------------- | -------------------------------------------------------- |
| [`@lmc-eu/spirit-analytics`](./packages/analytics) | Analytic tools for Spirit Design System | [![@lmc-eu/spirit-analytics][sa-badge]][sa-npm] |
| [`@lmc-eu/spirit-codemods`](./packages/codemods) | Codemod transforms for Spirit Design System version migration | [![@lmc-eu/spirit-codemods][sc-badge]][sc-npm] |
| [`@lmc-eu/spirit-common`](./packages/common) | Common scripts for Spirit Design System | Private |
| [`@lmc-eu/spirit-design-tokens`](./packages/design-tokens) | Design tokens for Spirit Design System | [![@lmc-eu/spirit-design-tokens][sdt-badge]][sdt-npm] |
| [`@lmc-eu/spirit-form-validations`](./packages/form-validations) | Form Validations for Spirit Design System | [![@lmc-eu/spirit-form-validations][sfv-badge]][sfv-npm] |
| [`@lmc-eu/spirit-icons`](./packages/icons) | Icons for Spirit Design System | [![@lmc-eu/spirit-icons][si-badge]][si-npm] |
| [`@lmc-eu/spirit-web`](./packages/web) | CSS and vanilla JS implementation of Spirit Design System | [![@lmc-eu/spirit-web][sw-badge]][sw-npm] |
| [`@lmc-eu/spirit-web-react`](./packages/web-react) | React implementation of Spirit Design System components | [![@lmc-eu/spirit-web-react][swr-badge]][swr-npm] |
| [`@lmc-eu/spirit-web-twig`](./packages/web-twig) | Twig implementation of Spirit Design System components | [![@lmc-eu/spirit-web-twig][swt-badge]][swt-packagist] |
| Package name | Description | Version |
| -------------------------------------------------------------- | ------------------------------------------------------------- | -------------------------------------------------------- |
| [`@lmc-eu/spirit-analytics`][packages-analytics] | Analytic tools for Spirit Design System | [![@lmc-eu/spirit-analytics][sa-badge]][sa-npm] |
| [`@lmc-eu/spirit-codemods`][packages-codemods] | Codemod transforms for Spirit Design System version migration | [![@lmc-eu/spirit-codemods][sc-badge]][sc-npm] |
| [`@lmc-eu/spirit-common`][packages-common] | Common scripts for Spirit Design System | Private |
| [`@lmc-eu/spirit-design-tokens`][packages-design-tokens] | Design tokens for Spirit Design System | [![@lmc-eu/spirit-design-tokens][sdt-badge]][sdt-npm] |
| [`@lmc-eu/spirit-form-validations`][packages-form-validations] | Form Validations for Spirit Design System | [![@lmc-eu/spirit-form-validations][sfv-badge]][sfv-npm] |
| [`@lmc-eu/spirit-icons`][packages-icons] | Icons for Spirit Design System | [![@lmc-eu/spirit-icons][si-badge]][si-npm] |
| [`@lmc-eu/spirit-web`][packages-web] | CSS and vanilla JS implementation of Spirit Design System | [![@lmc-eu/spirit-web][sw-badge]][sw-npm] |
| [`@lmc-eu/spirit-web-react`][packages-web-react] | React implementation of Spirit Design System components | [![@lmc-eu/spirit-web-react][swr-badge]][swr-npm] |
| [`@lmc-eu/spirit-web-twig`][packages-web-twig] | Twig implementation of Spirit Design System components | [![@lmc-eu/spirit-web-twig][swt-badge]][swt-packagist] |

## Development

### Prerequisites

- [NodeJS](https://nodejs.org)
- [Yarn](https://yarnpkg.com)
- [Lerna](https://lerna.js.org)
- [NodeJS][nodejs]
- [Yarn][yarn]
- [Lerna][lerna]

### Start Development

Expand All @@ -44,13 +44,31 @@ See individual [packages](#packages) to learn how to get started.
- `yarn install`
- `yarn start`

See [`package.json`](./package.json) for all available tasks.
See [`package.json`][package.json] for all available tasks.

## License

See the [LICENSE](LICENSE.md) file for information.
See the [LICENSE][license] file for information.

[alma-career]: https://github.com/lmc-eu
[code-quality-checks]: https://github.com/lmc-eu/spirit-design-system/actions
[code-quality-checks-svg]: https://github.com/lmc-eu/spirit-design-system/actions/workflows/test.yaml/badge.svg?branch=main
[coverage-status]: https://coveralls.io/github/lmc-eu/spirit-design-system?branch=main
[coverage-status-svg]: https://coveralls.io/repos/github/lmc-eu/spirit-design-system/badge.svg?branch=main
[lerna]: https://lerna.js.org
[lerna-svg]: https://img.shields.io/badge/maintained%20with-lerna-cc00ff.svg
[license]: https://github.com/lmc-eu/spirit-design-system/blob/main/LICENSE.md
[nodejs]: https://nodejs.org
[packages-analytics]: https://github.com/lmc-eu/spirit-design-system/tree/main/packages/analytics
[packages-codemods]: https://github.com/lmc-eu/spirit-design-system/tree/main/packages/codemods
[packages-common]: https://github.com/lmc-eu/spirit-design-system/tree/main/packages/common
[packages-design-tokens]: https://github.com/lmc-eu/spirit-design-system/tree/main/packages/design-tokens
[packages-form-validations]: https://github.com/lmc-eu/spirit-design-system/tree/main/packages/form-validations
[packages-icons]: https://github.com/lmc-eu/spirit-design-system/tree/main/packages/icons
[packages-web]: https://github.com/lmc-eu/spirit-design-system/tree/main/packages/web
[packages-web-react]: https://github.com/lmc-eu/spirit-design-system/tree/main/packages/web-react
[packages-web-twig]: https://github.com/lmc-eu/spirit-design-system/tree/main/packages/web-twig
[package.json]: https://github.com/lmc-eu/spirit-design-system/blob/main/package.json
[sa-badge]: https://img.shields.io/npm/v/%40lmc-eu/spirit-analytics.svg?style=flat-square
[sa-npm]: https://www.npmjs.com/package/@lmc-eu/spirit-analytics
[sc-badge]: https://img.shields.io/npm/v/%40lmc-eu/spirit-codemods.svg?style=flat-square
Expand All @@ -67,3 +85,4 @@ See the [LICENSE](LICENSE.md) file for information.
[swr-npm]: https://www.npmjs.com/package/@lmc-eu/spirit-web-react
[swt-badge]: https://img.shields.io/packagist/v/lmc/spirit-web-twig-bundle.svg?style=flat-square
[swt-packagist]: https://packagist.org/packages/lmc/spirit-web-twig-bundle
[yarn]: https://yarnpkg.com
4 changes: 2 additions & 2 deletions configs/jest-config-spirit/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -45,5 +45,5 @@ check out our [Contributing Guide][contributing]! 👀
Licensed under the [MIT][license].

[yarn]: https://yarnpkg.com/en/
[contributing]: /CONTRIBUTING.md
[license]: /LICENSE.md
[contributing]: https://github.com/lmc-eu/spirit-design-system/blob/main/CONTRIBUTING.md
[license]: https://github.com/lmc-eu/spirit-design-system/blob/main/LICENSE.md
4 changes: 2 additions & 2 deletions configs/prettier-config-spirit/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -33,5 +33,5 @@ check out our [Contributing Guide][contributing]! 👀
Licensed under the [MIT][license].

[yarn]: https://yarnpkg.com/en/
[contributing]: /CONTRIBUTING.md
[license]: /LICENSE.md
[contributing]: https://github.com/lmc-eu/spirit-design-system/blob/main/CONTRIBUTING.md
[license]: https://github.com/lmc-eu/spirit-design-system/blob/main/LICENSE.md
4 changes: 2 additions & 2 deletions configs/stylelint-config-spirit/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -33,5 +33,5 @@ check out our [Contributing Guide][contributing]! 👀
Licensed under the [MIT][license].

[yarn]: https://yarnpkg.com/en/
[contributing]: /CONTRIBUTING.md
[license]: /LICENSE.md
[contributing]: https://github.com/lmc-eu/spirit-design-system/blob/main/CONTRIBUTING.md
[license]: https://github.com/lmc-eu/spirit-design-system/blob/main/LICENSE.md
4 changes: 3 additions & 1 deletion docs/decisions/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,11 @@

### And I've got opinions...

![](./opinions.png)
![][opinions-image]

This directory contains all the decisions we've made for this design system as a record for whenever we wonder why certain decisions were made.

Decisions here are never final.
But these documents should serve as a good way for someone to come up to speed on why certain decisions were made.

[opinions-image]: https://github.com/lmc-eu/spirit-design-system/blob/main/docs/decisions/opinions.png?raw=true
2 changes: 1 addition & 1 deletion docs/postmortems/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -22,4 +22,4 @@ topic.

[learning-from-failure]: https://landing.google.com/sre/sre-book/chapters/postmortem-culture/
[sre-book]: https://landing.google.com/sre/sre-book/chapters/postmortem/
[postmorem-template]: ./0000-00-00-template.md
[postmortem-template]: https://github.com/lmc-eu/spirit-design-system/blob/main/docs/postmortems/0000-00-00-template.md
2 changes: 1 addition & 1 deletion packages/codemods/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,6 @@ npx @lmc-eu/spirit-codemods -p ./src -t v2/web-react/fileuploader-prop-names -e

## Available Scripts

- [Web-React v2 Codemods](./src/transforms/v2/web-react/README.md)
- [Web-React v2 Codemods](https://github.com/lmc-eu/spirit-design-system/blob/main/packages/codemods/src/transforms/v2/web-react/README.md)

[jscodeshift]: https://github.com/facebook/jscodeshift
2 changes: 1 addition & 1 deletion packages/codemods/src/transforms/v2/web-react/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

This is a collection of codemods for updating Web-React v2 components.

You can find instructions on how to run these codemods in the main package [README](./../../../../README.md).
You can find instructions on how to run these codemods in the main package [README](https://github.com/lmc-eu/spirit-design-system/blob/main/packages/codemods/README.md).

## Included Scripts

Expand Down
16 changes: 11 additions & 5 deletions packages/web-twig/CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ To start this project simply run `make start` and then add project certificates

In a moment the app will be setup and ready on `https://localhost:4443`.

Please consult [`Makefile`](./Makefile) for available commands and options to setup and run this project.
Please consult [`Makefile`][makefile] for available commands and options to setup and run this project.

## Components definition

Expand All @@ -34,7 +34,7 @@ This is an example of a typical file structure of a component:
## Rules in components

1. Name of components must be camelCase with first letter small.
2. New components must contain a property class so that they can be extended according to the [instructions](./docs/extendComponents.md)
2. New components must contain a property class so that they can be extended according to the [instructions](https://github.com/lmc-eu/spirit-design-system/blob/main/packages/web-twig/docs/extendComponents.md)

```twig
{% set _class = (props.class is defined) ? ' ' ~ props.class : '' -%}
Expand Down Expand Up @@ -66,11 +66,11 @@ Instead use:
{%- set _ariaHidden = props.ariaHidden ?? true -%}
```

See [default filter does not work issue](https://github.com/twigphp/Twig/issues/769) and [Twig default filter documentation](https://twig.symfony.com/doc/2.x/filters/default.html) for more information
See [default filter does not work issue][default-filter-issue] and [Twig default filter documentation][default-filter-documentation] for more information

### Unescaped Props

🚨 All props that uses [raw](https://twig.symfony.com/doc/3.x/filters/raw.html) filter must be prefixed with `UNSAFE_`.
🚨 All props that uses [raw][raw] filter must be prefixed with `UNSAFE_`.
These props are unescaped.
For example we used this prefix for props that can accept HTML string.

Expand Down Expand Up @@ -142,7 +142,7 @@ It is balanced between the DRY principle and how the PHPUnit works.

## Release new version

TODO: [Automate release process](https://github.com/lmc-eu/spirit-design-system/issues/393).
TODO: [Automate release process][automate-release-process].

As we are now using only `dev-main` version of this package, until we have stable release process, we are not able to release new version with release script and tag it.

Expand All @@ -167,3 +167,9 @@ Force push current changes to remote using subtree:
Or

- use `make publish pkg=web-twig` in repository root to publish changes to remote.

[automate-release-process]: https://github.com/lmc-eu/spirit-design-system/issues/393
[default-filter-issue]: https://github.com/twigphp/Twig/issues/769
[default-filter-documentation]: https://twig.symfony.com/doc/2.x/filters/default.html
[makefile]: https://github.com/lmc-eu/spirit-design-system/blob/main/packages/web-twig/Makefile
[raw]: https://twig.symfony.com/doc/3.x/filters/raw.html
18 changes: 12 additions & 6 deletions packages/web-twig/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ This is a Symfony bundle with Twig implementation of [Spirit Design System] comp

## Changelog

See [CHANGELOG](./CHANGELOG.md)
See [CHANGELOG][changelog]

## How to install

Expand Down Expand Up @@ -60,11 +60,11 @@ spirit_web_twig:
## Usage
For detailed usage see [TwigX bundle](https://github.com/lmc-eu/twigx-bundle/blob/main/README.md#usage)
For detailed usage see [TwigX bundle][twigx-bundle]
### Unescaped Props
All props that internally uses the [raw](https://twig.symfony.com/doc/3.x/filters/raw.html) filter are prefixed with `UNSAFE_`.
All props that internally uses the [raw][raw] filter are prefixed with `UNSAFE_`.
This is considered a way how you can pass down HTML strings.

```twig
Expand All @@ -73,10 +73,10 @@ This is considered a way how you can pass down HTML strings.

# Spirit Components

For available components see the [components directory](https://github.com/lmc-eu/spirit-design-system/tree/main/packages/web-twig/src/Resources/components).
For available components see the [components directory][components-directory].

if you want to extend these components, an example guide is [here](./docs/extendComponents.md).
if you want to contribute, read the guide [here](./CONTRIBUTING.md).
if you want to extend these components, an example guide is [here][example-guide].
if you want to contribute, read the guide [here][contributing].

## Additional Attributes

Expand Down Expand Up @@ -155,5 +155,11 @@ Check your Symfony console or log to see if you are using any of the deprecated

![Deprecations in Symfony's console](https://github.com/lmc-eu/spirit-design-system/blob/main/static/deprecations-symfony-console.png?raw=true)

[changelog]: https://github.com/lmc-eu/spirit-design-system/blob/main/packages/web-twig/CHANGELOG.md
[components-directory]: https://github.com/lmc-eu/spirit-design-system/tree/main/packages/web-twig/src/Resources/components
[contributing]: https://github.com/lmc-eu/spirit-design-system/blob/main/packages/web-twig/CONTRIBUTING.md
[example-guide]: https://github.com/lmc-eu/spirit-design-system/blob/main/packages/web-twig/docs/extendComponents.md
[raw]: https://twig.symfony.com/doc/3.x/filters/raw.html
[spirit design system]: https://github.com/lmc-eu/spirit-design-system
[twigx-bundle]: https://github.com/lmc-eu/twigx-bundle/blob/main/README.md#usage
[web-pkg-rebrand]: https://github.com/lmc-eu/spirit-design-system/tree/main/packages/web#rebranding
12 changes: 7 additions & 5 deletions packages/web/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -178,7 +178,7 @@ The dev-stack is based on [Vite].
This package uses the deprecation warnings for props, functions and components that will be removed or replaced in the next major release.
Check your browser console to see if you are using any of the deprecated functionality.

![Deprecations in the Browser's console](https://github.com/lmc-eu/spirit-design-system/blob/main/static/deprecations-browser-console.png?raw=true)
![Deprecations in the Browser's console][deprecations]

## Feature Flags

Expand All @@ -190,12 +190,14 @@ Check your browser console to see if you are using any of the deprecated functio

## License

See the [LICENSE](LICENSE.md) file for information.
See the [LICENSE][license] file for information.

[configuring-load-path]: https://github.com/lmc-eu/spirit-design-system/tree/main/packages/design-tokens#configuring-load-path
[feature-flags-docs]: ../../docs/contributtion/feature-flags.md
[tokens-api]: https://github.com/lmc-eu/spirit-design-system/tree/main/packages/design-tokens#tokens-api
[rebranding]: https://github.com/lmc-eu/spirit-design-system/tree/main/packages/design-tokens#b-via-load-path
[deprecations]: https://github.com/lmc-eu/spirit-design-system/blob/main/static/deprecations-browser-console.png?raw=true
[examples]: https://spirit-design-system.netlify.app/packages/web/
[feature-flags-docs]: https://github.com/lmc-eu/spirit-design-system/blob/main/docs/contributtion/feature-flags.md
[license]: https://github.com/lmc-eu/spirit-design-system/blob/main/packages/web/LICENSE.md
[postcss-prefix-selector]: https://www.npmjs.com/package/postcss-prefix-selector
[rebranding]: https://github.com/lmc-eu/spirit-design-system/tree/main/packages/design-tokens#b-via-load-path
[tokens-api]: https://github.com/lmc-eu/spirit-design-system/tree/main/packages/design-tokens#tokens-api
[vite]: https://vitejs.dev

0 comments on commit ebd2b3f

Please sign in to comment.