Skip to content

Commit 9fce20f

Browse files
Concorde update
0 parents  commit 9fce20f

File tree

362 files changed

+30354
-0
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

362 files changed

+30354
-0
lines changed

.eslintrc.yaml

Lines changed: 36 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,36 @@
1+
---
2+
parser: "@typescript-eslint/parser"
3+
extends:
4+
- "@epilot/eslint-config-react"
5+
- "plugin:@typescript-eslint/recommended"
6+
- "plugin:prettier/recommended"
7+
- "plugin:storybook/recommended"
8+
- "prettier"
9+
env:
10+
jest: true
11+
settings:
12+
import/resolver:
13+
node:
14+
extensions:
15+
- ".js"
16+
- ".jsx"
17+
- ".ts"
18+
- ".tsx"
19+
paths:
20+
- src
21+
typescript: true
22+
parserOptions:
23+
ecmaVersion: 2020
24+
sourceType: module
25+
ecmaFeatures:
26+
jsx: true
27+
ignorePatterns:
28+
- "/node_modules/*"
29+
- "/dist/*"
30+
- "**/*.module.scss.d.ts"
31+
rules:
32+
"no-console": "error"
33+
"@typescript-eslint/consistent-type-imports": "error"
34+
"@typescript-eslint/ban-types": "off"
35+
"prettier/prettier": "error"
36+
"@typescript-eslint/no-unused-vars-experimental": "off"

.github/workflows/node.js.yml

Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,25 @@
1+
# This workflow will do a clean installation of node dependencies, cache/restore them, build the source code and run tests across different versions of node
2+
# For more information see: https://docs.github.com/en/actions/automating-builds-and-tests/building-and-testing-nodejs
3+
4+
name: Install Dependencies
5+
6+
on:
7+
push:
8+
branches: ["main"]
9+
pull_request:
10+
branches: ["main"]
11+
12+
jobs:
13+
install-dependencies:
14+
runs-on: ubuntu-latest
15+
16+
strategy:
17+
matrix:
18+
node-version: [22.x]
19+
# See supported Node.js release schedule at https://nodejs.org/en/about/releases/
20+
21+
steps:
22+
- uses: actions/checkout@v4
23+
- name: Use Node.js ${{ matrix.node-version }}
24+
uses: actions/setup-node@v4
25+
- run: npm i --force

.gitignore

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
*.log
2+
.DS_Store
3+
node_modules
4+
storybook-static
5+
.cache
6+
dist
7+
.vscode
8+
.idea
9+
.eslintcache
10+
.npmrc
11+
test-report.xml
12+
.yarn
13+
build-storybook.log
14+
**/*.module.scss.d.ts
15+
16+
*storybook.log

.storybook/main.ts

Lines changed: 37 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,37 @@
1+
import type { StorybookConfig } from "@storybook/react-vite";
2+
3+
import { join, dirname } from "path";
4+
5+
/**
6+
* This function is used to resolve the absolute path of a package.
7+
* It is needed in projects that use pnpm PnP or are set up within a monorepo.
8+
*/
9+
function getAbsolutePath(value: string): any {
10+
return dirname(require.resolve(join(value, "package.json")));
11+
}
12+
const config: StorybookConfig = {
13+
stories: ["../src/**/*.mdx", "../src/**/*.stories.@(js|jsx|mjs|ts|tsx)"],
14+
addons: [
15+
getAbsolutePath("@storybook/addon-links"),
16+
getAbsolutePath("@storybook/addon-essentials"),
17+
getAbsolutePath("@chromatic-com/storybook"),
18+
getAbsolutePath("@storybook/addon-interactions"),
19+
getAbsolutePath("@storybook/addon-a11y"),
20+
],
21+
framework: {
22+
name: getAbsolutePath("@storybook/react-vite"),
23+
options: {},
24+
},
25+
docs: {
26+
autodocs: "tag",
27+
},
28+
async viteFinal(config) {
29+
const { mergeConfig } = await import('vite');
30+
return mergeConfig(config, {
31+
optimizeDeps: {
32+
exclude: ['axios'],
33+
},
34+
});
35+
},
36+
};
37+
export default config;

.storybook/preview.ts

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
import type { Preview } from '@storybook/react'
2+
// Imports styles for story only because journey-app has styles already
3+
import 'material-symbols/sharp.css'
4+
import 'material-symbols/rounded.css'
5+
import '../src/global.css'
6+
import 'react-datepicker/dist/react-datepicker.css'
7+
8+
const preview: Preview = {
9+
tags: ['autodocs']
10+
}
11+
12+
export default preview

CHANGELOG.md

Lines changed: 611 additions & 0 deletions
Large diffs are not rendered by default.

LICENSE

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
The MIT License (MIT)
2+
3+
Copyright (c) 2024 e.pilot GmbH
4+
5+
Permission is hereby granted, free of charge, to any person obtaining a copy
6+
of this software and associated documentation files (the "Software"), to deal
7+
in the Software without restriction, including without limitation the rights
8+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9+
copies of the Software, and to permit persons to whom the Software is
10+
furnished to do so, subject to the following conditions:
11+
12+
The above copyright notice and this permission notice shall be included in
13+
all copies or substantial portions of the Software.
14+
15+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
21+
THE SOFTWARE.

README.md

Lines changed: 40 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,40 @@
1+
<h1 align="center"><img alt="epilot-logo" src="https://github.com/epilot-dev/concorde-elements/blob/main/docs/assets/logo.png?raw=true" width="200"><br>epilot-elements</h1>
2+
3+
[![CI](https://github.com/epilot-dev/concorde-elements/actions/workflows/node.js.yml/badge.svg)](https://github.com/epilot-dev/concorde-elements/actions/workflows/node.js.yml)
4+
[![NPM Version](https://img.shields.io/npm/v/%40epilot%2Fconcorde-elements)](https://www.npmjs.com/package/@epilot/concorde-elements)
5+
[![License](http://img.shields.io/:license-mit-blue.svg)](https://github.com/epilot-dev/concorde-elements/blob/main/)
6+
7+
This is a multi purpose UI library used internally by epilot journeys. It could be used for any kind of projects, including building apps for epilot journeys.
8+
9+
Concorde was the internal code name used by epilot devs to migrate epilot journeys to use a more modern ui components. The goal was enhance the UX while making it simple & fast.
10+
11+
## Quick Start
12+
13+
### Installation
14+
15+
Install the package via npm:
16+
17+
```sh
18+
npm install --save @epilot/concorde-elements
19+
```
20+
21+
### Usage
22+
23+
Components could be simply used like:
24+
25+
```typescript
26+
import { Button } from '@epilot/concorde-elements'
27+
28+
export function SomeComponent() {
29+
return (<Button variant='primary' label='Hello' />)
30+
}
31+
```
32+
33+
# Documentation
34+
35+
- [Storybook](https://portal.epilot.cloud/concorde-elements)
36+
- [Developing for epilot Journeys](https://docs.epilot.io/docs/journeys/developer-resources)
37+
38+
# Contributing
39+
40+
The epilot elements library is a free and open source software. PRs welcome! 🚀

docs/assets/logo.png

36.9 KB
Loading

package.json

Lines changed: 131 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,131 @@
1+
{
2+
"name": "@epilot/concorde-elements",
3+
"version": "0.0.15",
4+
"license": "MIT",
5+
"author": {
6+
"name": "epilot GmbH",
7+
"email": "[email protected]",
8+
"url": "https://epilot.cloud"
9+
},
10+
"sideEffects": [
11+
"**/*.css"
12+
],
13+
"type": "module",
14+
"main": "src/index.ts",
15+
"types": "src/index.ts",
16+
"scripts": {
17+
"build": "npm run build-storybook",
18+
"build:package": "rm -rf dist && NODE_ENV=production vite build",
19+
"build-storybook": "NODE_ENV=production storybook build",
20+
"changelog": "npx conventional-changelog -i CHANGELOG.md -s --commit-path . @epilot/concorde-elements",
21+
"chromatic": "npx chromatic --project-token=chpt_cef42bf3c35609d",
22+
"lint": "eslint src --ext js,ts,tsx --cache",
23+
"lint:fix": "eslint src --ext js,ts,tsx --fix --cache",
24+
"storybook": "storybook dev -p 6006",
25+
"test": "TZ=UTC vitest run",
26+
"test:watch": "vitest watch",
27+
"prepublishOnly": "npm version patch && pnpm changelog && pnpm lint && pnpm test && pnpm build:package",
28+
"release": "pnpm publish",
29+
"postpublish": "git add package.json CHANGELOG.md && git commit -m \"chore: update concorde published version\" && git push && git push --tags"
30+
},
31+
"browserslist": [
32+
">0.2%",
33+
"not dead",
34+
"not op_mini all"
35+
],
36+
"dependencies": {
37+
"@floating-ui/dom": "^1.6.13",
38+
"@mui/base": "5.0.0-beta.61",
39+
"@mui/utils": "^6.2.0",
40+
"@radix-ui/react-checkbox": "^1.1.2",
41+
"@radix-ui/react-dialog": "1.1.2",
42+
"@radix-ui/react-dropdown-menu": "^2.1.2",
43+
"@radix-ui/react-popover": "^1.1.2",
44+
"@radix-ui/react-progress": "^1.1.1",
45+
"@radix-ui/react-radio-group": "^1.3.7",
46+
"@radix-ui/react-slot": "1.1.2",
47+
"@radix-ui/react-switch": "^1.1.1",
48+
"@radix-ui/react-toggle": "^1.1.0",
49+
"@radix-ui/react-toggle-group": "^1.1.0",
50+
"@radix-ui/react-tooltip": "^1.1.4",
51+
"culori": "^4.0.1",
52+
"date-fns": "^3.6.0",
53+
"file-selector": "*",
54+
"motion": "^11.15.0",
55+
"radashi": "*",
56+
"react-datepicker": "^8.3.0",
57+
"react-dropzone": "^11.4.2",
58+
"react-hook-form": "^7.53.0",
59+
"react-input-mask": "^2.0.4",
60+
"react-keyed-flatten-children": "^3.0.2",
61+
"react-number-format": "^5.4.3",
62+
"react-swipeable-views": "^0.14.0"
63+
},
64+
"devDependencies": {
65+
"@chromatic-com/storybook": "^1.3.5",
66+
"@epilot/eslint-config-react": "^1.2.15",
67+
"@epilot/validators": "latest",
68+
"@storybook/addon-a11y": "^8.6.11",
69+
"@storybook/addon-essentials": "^8.5.4",
70+
"@storybook/addon-interactions": "^8.5.4",
71+
"@storybook/addon-links": "^8.5.4",
72+
"@storybook/blocks": "^8.5.4",
73+
"@storybook/react": "^8.5.4",
74+
"@storybook/react-vite": "^8.5.4",
75+
"@storybook/test": "^8.5.4",
76+
"@testing-library/jest-dom": "*",
77+
"@testing-library/react": "*",
78+
"@testing-library/user-event": "*",
79+
"@types/babel__generator": "^7.6.8",
80+
"@types/culori": "^2.1.1",
81+
"@types/react": "*",
82+
"@types/react-dom": "*",
83+
"@types/react-input-mask": "3.0.0",
84+
"@types/react-swipeable-views": "^0.13.5",
85+
"@types/testing-library__jest-dom": "*",
86+
"@typescript-eslint/eslint-plugin": "6.5.0",
87+
"@typescript-eslint/parser": "6.5.0",
88+
"@vitejs/plugin-react": "^4.2.1",
89+
"autoprefixer": "^10.4.19",
90+
"chromatic": "^11.3.2",
91+
"classnames": "^2.5.1",
92+
"conventional-changelog": "^7.1.1",
93+
"eslint": "*",
94+
"eslint-config-prettier": "8.0.0",
95+
"eslint-import-resolver-typescript": "^3.6.3",
96+
"eslint-plugin-import": "2.30.0",
97+
"eslint-plugin-prettier": "5.2.1",
98+
"eslint-plugin-react-hooks": "4.6.2",
99+
"eslint-plugin-storybook": "^0.8.0",
100+
"i18next": "*",
101+
"jsdom": "^25.0.0",
102+
"material-symbols": "latest",
103+
"prettier": "*",
104+
"react": "^18.0.0",
105+
"react-i18next": "*",
106+
"storybook": "^8.5.4",
107+
"terser": "5.32.0",
108+
"tslib": "^2.3.1",
109+
"typescript": "^5.4.5",
110+
"use-debounce": "^6.0.1",
111+
"vite": "*",
112+
"vite-plugin-dts": "^4.5.0",
113+
"vite-plugin-lib-inject-css": "^2.2.1",
114+
"vite-plugin-sass-dts": "^1.3.30",
115+
"vitest": "*",
116+
"vitest-axe": "^0.1.0"
117+
},
118+
"peerDependencies": {
119+
"@epilot/validators": "^0.0.21",
120+
"react": ">=17.0.0",
121+
"react-dom": "^18.2.0",
122+
"react-i18next": "*"
123+
},
124+
"files": [
125+
"dist/**"
126+
],
127+
"publishConfig": {
128+
"main": "dist/index.js",
129+
"types": "dist/index.d.ts"
130+
}
131+
}

0 commit comments

Comments
 (0)