diff --git a/.github/renovate.json b/.github/renovate.json index 22a8b6f8573..36d80b776d5 100644 --- a/.github/renovate.json +++ b/.github/renovate.json @@ -72,21 +72,21 @@ ] }, { - "description": "Example & Template dependencies", + "description": "Example,Template & Pattern dependencies", "extends": ["schedule:weekly"], - "matchFileNames": ["examples/**", "templates/**"], + "matchFileNames": ["examples/**", "templates/**", "patterns/**"], "semanticCommitType": "chore", - "groupName": "all non-major dependencies (examples & templates)", + "groupName": "all non-major dependencies (examples, templates & patterns)", "groupSlug": "examples-all-minor-patch", "matchUpdateTypes": ["minor", "patch"], "matchBaseBranches": ["main"], "matchPackageNames": ["*", "!/^@ui5//"] }, { - "description": "UI5 Web Components (for React) in all examples & templates", - "groupName": "UI5 Web Components React (examples & templates)", + "description": "UI5 Web Components (for React) in all examples, templates & patterns", + "groupName": "UI5 Web Components React (examples, templates & patterns)", "groupSlug": "examples-ui5-webcomponents-react", - "matchFileNames": ["examples/**", "templates/**"], + "matchFileNames": ["examples/**", "templates/**", "patterns/**"], "semanticCommitType": "chore", "matchBaseBranches": ["main"], "matchSourceUrls": [ diff --git a/.github/workflows/examples.yml b/.github/workflows/examples.yml index 90fb5a0c39c..4f7789d90e5 100644 --- a/.github/workflows/examples.yml +++ b/.github/workflows/examples.yml @@ -7,10 +7,12 @@ on: paths: - 'examples/**/*' - 'templates/**/*' + - 'patterns/navigation-layout/**/*' pull_request: paths: - 'examples/**/*' - 'templates/**/*' + - 'patterns/navigation-layout/**/*' jobs: examples: @@ -77,3 +79,33 @@ jobs: - name: ESLint run: npm run lint --if-present working-directory: templates/${{ matrix.path }} + + patterns: + runs-on: ubuntu-latest + strategy: + matrix: + path: + - navigation-layout + fail-fast: false + steps: + - uses: actions/checkout@v4 + + - uses: actions/setup-node@v4.4.0 + with: + node-version-file: '.nvmrc' + + - name: Install + run: npm ci + working-directory: patterns/${{ matrix.path }} + + - name: Build + run: npm run build + working-directory: patterns/${{ matrix.path }} + + - name: Test + run: npm run test --if-present + working-directory: patterns/${{ matrix.path }} + + - name: ESLint + run: npm run lint --if-present + working-directory: patterns/${{ matrix.path }} diff --git a/.storybook/docs/DesignCompliantExampleSection.md b/.storybook/docs/DesignCompliantExampleSection.md new file mode 100644 index 00000000000..65fdf1c7961 --- /dev/null +++ b/.storybook/docs/DesignCompliantExampleSection.md @@ -0,0 +1,3 @@ +## Design-Compliant Examples + +These examples demonstrate the implementation of design specifications. They primarily illustrate design concepts and mostly do not provide additional functionality. You can reference them to select the appropriate design patterns. diff --git a/.storybook/preview.tsx b/.storybook/preview.tsx index 48703f72327..3fd9ca9f5f8 100644 --- a/.storybook/preview.tsx +++ b/.storybook/preview.tsx @@ -144,6 +144,7 @@ const preview: Preview = { 'Knowledge Base', 'Testing with Cypress', ['Setup', 'Commands', 'Queries'], + 'Patterns', 'Charts', ['Docs'], 'Data Display', diff --git a/docs/EmbeddedStackBlitz.tsx b/docs/EmbeddedStackBlitz.tsx new file mode 100644 index 00000000000..d7a714bd45f --- /dev/null +++ b/docs/EmbeddedStackBlitz.tsx @@ -0,0 +1,34 @@ +import sdk from '@stackblitz/sdk'; +import { useEffect, useRef } from 'react'; + +interface EmbeddedStackBlitzProps { + repoPath: string; +} + +export function EmbeddedStackBlitz({ repoPath }: EmbeddedStackBlitzProps) { + const containerRef = useRef(null); + + useEffect(() => { + const container = containerRef.current; + if (!container) { + return; + } + sdk.embedGithubProject(container, repoPath, { + openFile: 'src/App.tsx', + view: 'editor', + height: '90%', + hideDevTools: true, + terminalHeight: 0, + }); + + return () => { + if (container) { + container.innerHTML = ''; + } + }; + }, [repoPath]); + + return
; +} + +EmbeddedStackBlitz.displayName = 'EmbeddedStackBlitz'; diff --git a/docs/Patterns.mdx b/docs/Patterns.mdx new file mode 100644 index 00000000000..4415ee52364 --- /dev/null +++ b/docs/Patterns.mdx @@ -0,0 +1,11 @@ +import {Footer} from '@sb/components'; +import {Meta} from '@storybook/blocks'; +import UXCIntegration from "./UXCIntegration.js" + + + +# UXC Integration + + + +