Skip to content

Commit

Permalink
Merge branch 'main' into update-testing-lib-act
Browse files Browse the repository at this point in the history
  • Loading branch information
sebald committed Jun 28, 2024
2 parents 1fec9cc + 0773aa8 commit a0f962c
Show file tree
Hide file tree
Showing 49 changed files with 1,336 additions and 1,151 deletions.
11 changes: 11 additions & 0 deletions .changeset/fifty-seals-divide.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
---
"@marigold/eslint-config": patch
"@marigold/jest-config": patch
"@marigold/storybook-config": patch
"@marigold/docs": patch
"@marigold/components": major
"@marigold/system": major
"@marigold/types": patch
---

refa: Update TypeScript and adjust `<NumericFormat>` props
5 changes: 5 additions & 0 deletions .changeset/honest-kids-sit.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@marigold/docs": patch
---

[DST-446]docs: adding governance process page
5 changes: 5 additions & 0 deletions .changeset/long-horses-impress.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@marigold/docs": patch
---

docs[DST-465]: adding message pattern to documentation
2 changes: 1 addition & 1 deletion .github/renovate.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
":semanticCommitTypeAll(chore)",
":rebaseStalePrs"
],
"schedule": ["earlyMondays"],
"schedule": ["before 4am on Monday"],
"packageRules": [
{
"matchDatasources": ["npm"],
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ jobs:
steps:
# Setup
- uses: actions/checkout@v4
- uses: pnpm/action-setup@v3.0.0 # Uses version from package.json#packageManager
- uses: pnpm/action-setup@v4.0.0 # Uses version from package.json#packageManager
- name: Setup Node (using .node-version)
uses: actions/setup-node@v4
with:
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/lint.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ jobs:
steps:
# Setup
- uses: actions/checkout@v4
- uses: pnpm/action-setup@v3.0.0 # Uses version from package.json#packageManager
- uses: pnpm/action-setup@v4.0.0 # Uses version from package.json#packageManager
- name: Setup Node (using .node-version)
uses: actions/setup-node@v4
with:
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ jobs:
steps:
# Setup
- uses: actions/checkout@v4
- uses: pnpm/action-setup@v3.0.0 # Uses version from package.json#packageManager
- uses: pnpm/action-setup@v4.0.0 # Uses version from package.json#packageManager
- name: Setup Node (using .node-version)
uses: actions/setup-node@v4
with:
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ jobs:
steps:
# Setup
- uses: actions/checkout@v4
- uses: pnpm/action-setup@v3.0.0 # Uses version from package.json#packageManager
- uses: pnpm/action-setup@v4.0.0 # Uses version from package.json#packageManager
- name: Setup Node (using .node-version)
uses: actions/setup-node@v4
with:
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/typecheck.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ jobs:
steps:
# Setup
- uses: actions/checkout@v4
- uses: pnpm/action-setup@v3.0.0 # Uses version from package.json#packageManager
- uses: pnpm/action-setup@v4.0.0 # Uses version from package.json#packageManager
- name: Setup Node (using .node-version)
uses: actions/setup-node@v4
with:
Expand Down
8 changes: 4 additions & 4 deletions config/eslint/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -23,8 +23,8 @@
"@babel/eslint-parser": "^7.22.10",
"@babel/plugin-syntax-flow": "^7.16.7",
"@babel/plugin-transform-react-jsx": "^7.17.3",
"@typescript-eslint/eslint-plugin": "7.13.1",
"@typescript-eslint/parser": "7.13.1",
"@typescript-eslint/eslint-plugin": "7.14.1",
"@typescript-eslint/parser": "7.14.1",
"eslint-config-prettier": "^9.0.0",
"eslint-config-react-app": "7.0.1",
"eslint-plugin-flowtype": "^8.0.3",
Expand All @@ -35,7 +35,7 @@
"eslint-plugin-react": "7.34.2",
"eslint-plugin-react-hooks": "^4.6.0",
"eslint-plugin-testing-library": "6.2.0",
"prettier": "3.2.5"
"prettier": "3.3.2"
},
"peerDependencies": {
"eslint": "8.x.x",
Expand All @@ -44,6 +44,6 @@
"devDependencies": {
"eslint": "8.57.0",
"eslint-plugin-tailwindcss": "3.17.3",
"typescript": "5.3.3"
"typescript": "5.5.2"
}
}
2 changes: 1 addition & 1 deletion config/jest/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,6 @@
"jest": "29.7.0",
"jest-transform-css": "6.0.1",
"react": "18.3.1",
"typescript": "5.3.3"
"typescript": "5.5.2"
}
}
26 changes: 13 additions & 13 deletions config/storybook/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -22,30 +22,30 @@
"@marigold/theme-b2b": "workspace:*",
"@marigold/theme-core": "workspace:*",
"@mdx-js/react": "3.0.1",
"@storybook/addon-a11y": "^8.0.6",
"@storybook/addon-essentials": "^8.0.6",
"@storybook/addon-interactions": "^8.0.6",
"@storybook/source-loader": "^8.0.6",
"@storybook/test": "^8.0.6",
"@storybook/addon-a11y": "^8.1.11",
"@storybook/addon-essentials": "^8.1.11",
"@storybook/addon-interactions": "^8.1.11",
"@storybook/source-loader": "^8.1.11",
"@storybook/test": "^8.1.11",
"@types/react": "18.3.3",
"@vitejs/plugin-react": "4.3.1",
"vite-tsconfig-paths": "4.3.2"
},
"devDependencies": {
"@storybook/addon-storysource": "^8.0.6",
"@storybook/addon-themes": "^8.0.6",
"@storybook/cli": "^8.0.6",
"@storybook/core-events": "^8.0.6",
"@storybook/preview-api": "^8.0.6",
"@storybook/react-vite": "^8.0.6",
"@storybook/addon-storysource": "^8.1.11",
"@storybook/addon-themes": "^8.1.11",
"@storybook/cli": "^8.1.11",
"@storybook/core-events": "^8.1.11",
"@storybook/preview-api": "^8.1.11",
"@storybook/react-vite": "^8.1.11",
"autoprefixer": "10.4.19",
"postcss": "8.4.38",
"postcss-loader": "8.1.1",
"react": "18.3.1",
"react-dom": "18.3.1",
"storybook": "^8.0.6",
"storybook": "^8.1.11",
"tailwindcss": "3.4.4",
"typescript": "5.3.3",
"typescript": "5.5.2",
"vite": "5.3.1"
},
"peerDependencies": {
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
{
"rules": {
"react/style-prop-object": "off"
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -29,11 +29,7 @@ export default () => {
<Radio value="EUR">EUR</Radio>
<Radio value="JPY">JPY</Radio>
</Radio.Group>
<NumericFormat
styleFormat="currency"
value={233}
currency={currentFormat}
/>
<NumericFormat style="currency" value={233} currency={currentFormat} />
</Inline>
</I18nProvider>
);
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
---
title: NumericFormat
caption: Helper component for formatting numeric based on the current language and locale-specific conventions.
badge: updated
---

With `<NumericFormat>` helper, you can easily ensure that numeric values are displayed consistently and accurately, taking into account factors such as decimal separators, currency symbols, and grouping separators specific to each language.
Expand Down
Original file line number Diff line number Diff line change
@@ -1,9 +1,5 @@
import { NumericFormat } from '@marigold/system';

export default () => (
<NumericFormat
styleFormat="percent"
value={0.7333}
minimumFractionDigits={2}
/>
<NumericFormat style="percent" value={0.7333} minimumFractionDigits={2} />
);
198 changes: 198 additions & 0 deletions docs/content/introduction/governance-process.mdx
Original file line number Diff line number Diff line change
@@ -0,0 +1,198 @@
---
title: Governance process
caption: Making changes and additions to Marigold.
order: 6
badge: new
---

Product teams are primarily focused on getting the job done. In their quest to achieve this, they sometimes need to take on design debt—improvising styles, crafting unique components, or even bypassing the design system entirely. To help teams avoid unnecessary debt, we've established a governance process that guides both the product teams and us on managing changes and additions within Marigold.

This process ensures that any modifications to the design system are carefully evaluated to maintain consistency, stability, and user-friendliness. We prioritize updates that meet specific user needs, adhere to industry standards, and offer high reusability. Guided by our [Governance values and principles](/introduction/governance-values), this approach helps uphold the quality and integrity of our design system.

If you ever asked yourself what we do with your feature requests or what you should do if we declined your request, you've come to the right place.

We have created a flowchart, divided into 3 phases, that illustrates how incoming feature requests are handled.

<SectionMessage>
<SectionMessage.Title>Note</SectionMessage.Title>
<SectionMessage.Content>
ug fixes aren't subject to the same rigorous evaluation process and are
handled differently. To read more about how to report bugs go
[here](/introduction//get-in-touch/#report-bugs).
</SectionMessage.Content>
</SectionMessage>

<p />

<iframe
title="governance flowchart"
className="border-border-base border"
width="100%"
height="480"
src="https://www.figma.com/embed?embed_host=share&url=https%3A%2F%2Fwww.figma.com%2Ffile%2FXnvTRolISplT6ZKtLYS8KG%2FManaging-Changes-and-Additions-to-the-Design-System%253A-Flowchart%3Ftype%3Dwhiteboard%26node-id%3D0%253A1%26t%3Db3p2S27ZxriQPK27-1"
allowfullscreen
/>

## Phase 1: Product team discovers a problem

What should you do if, while using the design system, you discover it's unable to provide something you need?

<Columns columns={[5, 5]} space={4}>
<div>
**Step 1:** The process begins when the product team discovers a problem with
Marigold, which could be, for example, a missing, broken, or
non-user-friendly component.

**Step 2:** The product team should first try to discover whether the Design System offers an existing alternative to solve the problem.

- **Yes:** If a viable alternative exists within the design system, the product team should use it.

- **No:** If there is no viable alternative, the product team should write a [request(internal only)](https://reservix.atlassian.net/servicedesk/customer/portal/77).

If the product team writes a support ticket, this triggers phase 2.

</div>
<Image width={700} height={900} src="/governance-phase1.png" alt="governance phase 1" />
</Columns>

## Phase 2: Design system team evaluates the request

This phase is only relevant if you have written a support ticket. This phase explains what happens to your request and how we evaluate it.

<Stack space={4}>
<Columns columns={[5, 5]} space={4}>
<div>
**Step 1:** If we have received a request through our [support portal (internal only)](https://reservix.atlassian.net/servicedesk/customer/portal/77) we have to check if there is clear evidence of user need.

- **Yes:** If there is clear evidence of user need, move to step 2.

- **No:** If there isn't clear evidence, the request is declined, and alternative solutions are offered.

</div>
<Image width={700} height={900} src="/governance-phase2-1.png" alt="governance phase 2 step 1" />
</Columns>
<Columns columns={[5, 5]} space={4}>
<div>
**Step 2:** For the next decision we have to check if the requested change will feel familiar to our users, i.e., if it is consistent with broader UX standards.

- **Yes:** If the requested change will feel familiar to users, move to step 3.

- **No:** If it won't feel familiar the request is declined and alternative solutions are offered.
</div>
<Image width={700} height={900} src="/governance-phase2-2.png" alt="governance phase 2 step 2" />
</Columns>
<Columns columns={[5, 5]} space={4}>
<div>
**Step 3:** We have to check if the change is likely to be reusable across multiple products.

- **Yes:** If the change is likely to be reusable across multiple products, we approve the request.

- **No:** If it isn't likely to be reusable, the request is declined, and alternative solutions are offered.
</div>
<Image width={700} height={900} src="/governance-phase2-3.png" alt="governance phase 2 step 3" />
</Columns>
<Columns columns={[5, 5]} space={4}>
<div>
**Step 4:** The next step is to determine the estimated timeline, including the roadmap and estimated effort.

**Step 5:** The product team decides if the estimated implementation timeline will meet their needs.

- **Yes:** If the estimated timeline works for the product team, the product team waits for delivery ​while the Design System Team proceeds to Phase 3a.

- **No:** If the estimated timeline does not work, the process goes to Phase 3b.
</div>
<Image width={700} height={900} src="/governance-phase2-4.png" alt="governance phase 2 step 4" />
</Columns>

</Stack>

## Phase 3a: Design system team fulfills the request

This phase can only be achieved if the estimated time for the request is acceptable for you and your team and you are willing to wait for us to deliver it. ​In that case, you can follow the process below.

<Columns columns={[5, 5]} space={4}>
<div>
**Step 1:** We start designing the request or addition.

**Step 2:** Does the design fulfill [WCAG 2.1 AA](https://www.w3.org/TR/WCAG21/) requirements:

- **Yes:** If the result meets [WCAG 2.1 AA](https://www.w3.org/TR/WCAG21/) requirements, proceed to testing.

- **No:** If it does not meet these requirements, the design decisions must be revisited.

**Step 3:** Test the design in real-world environments, ideally with real users.

**Step 4:** We need to check if the solution meets the three key criteria: user need, familiarity, and reusability.

- **Yes:** If it still meets all three criteria, proceed to the voting stage in step 5.

- **No:** If it does not meet the criteria, iterate on the design.

**Step 5:** The Design System Team and major stakeholders (e.g., UX/UI Community of Practice) vote on the solution. Is there agreement?

- **Yes:** If there is consensus, proceed to documentation.

- **No:** If there is no consensus, revisit the design and address concerns.

**Step 6:** We document the approved changes.

**Step 7:** We merge the changes to the codebase.

**Step 8:** We communicate the change or addition.

</div>
<Image
width={700}
height={900}
src="/governance-phase3a.png"
alr="governance phase 3a"
/>
</Columns>

## Phase 3b: Product team’s response if request can’t or won’t be fulfilled

What if you cannot wait for us to deliver a request, or we decide it doesn't meet our criteria for becoming part of the design system?​

<Columns columns={[5, 5]} space={4}>
<div>
**Step 1:** The product team must decide if they are still convinced of the need for their request.

- **Yes:** If the product team is still convinced of the need for the request, they proceed to step 2.

- **No:** If the product team is no longer convinced of the need for the request, the process ends, and the product team re-examines their requirements.

**Step 2:** If the product team is still convinced of the need for the request, they can choose to build their own component or solution, receiving support as needed​ from the design system team.

**Step 3:** Throughout the development process, the product team frequently coordinates with the design system team to ensure alignment and adherence to guidelines.

**Step 4:** The product team ensures that all design tokens and sub-elements used in their solution are sourced from the design system as much as possible to maintain consistency.

**Step 5:** The product team takes ownership of the custom solution they have developed. They document the solution and maintain it.

**Step 6:** If, at some point, a viable alternative becomes available, the product team can decide to use it in place of their custom solution.

- **Yes:** If a viable alternative becomes available in the design system, the product team removes their custom solution and implements the official one.

- **No:** If there is still no alternative available in the design system the product team continue to maintain their custom solution.

</div>
<Image
width={700}
height={900}
src="/governance-phase3b.png"
alt="governance phase 3b"
/>

</Columns>

<SectionMessage>
<SectionMessage.Title>
End of process
</SectionMessage.Title>
<SectionMessage.Content>
With end of Phase 3a the request is fulfilled and the process of making changes and additions is done. 🎉

In Phase 3b, the process concludes either with the product team maintaining the change or awaiting an alternative solution from the Design System Team.

</SectionMessage.Content>
</SectionMessage>
Loading

0 comments on commit a0f962c

Please sign in to comment.