Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,8 @@ repos:
hooks:
- id: biome-check
additional_dependencies: ["@biomejs/biome@1.9.4"]
- id: biome-format
additional_dependencies: ["@biomejs/biome@1.9.4"]
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v4.3.0
hooks:
Expand Down
13 changes: 13 additions & 0 deletions frontend-styleguide/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
# Python Italia's component library for PyCon Italia (and related events)

We use [Storybook](https://storybook.js.org/) to generate a UI component style guide that you can use on the Python Italia websites.

## Getting Started

```shell
pnpm install

pnpm storybook
```

Open [http://localhost:6006](http://localhost:6006) with your browser to see the result.
50 changes: 50 additions & 0 deletions frontend-styleguide/biome.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,50 @@
{
"$schema": "https://biomejs.dev/schemas/1.7.1/schema.json",
"organizeImports": {
"enabled": true
},
"linter": {
"enabled": true,
"rules": {
"recommended": true,
"correctness": {
"useExhaustiveDependencies": "off"
},
"style": {
"noNonNullAssertion": "off"
},
"suspicious": {
"noExplicitAny": "off",
"noArrayIndexKey": "off"
},
"a11y": {
"useKeyWithClickEvents": "off"
},
"complexity": {
"noForEach": "off"
},
"security": {
"noDangerouslySetInnerHtml": "off"
}
}
},
"formatter": {
"enabled": true,
"indentStyle": "space"
},
"files": {
"ignore": [
"**/lodash-is-equal.ts",
".cache/",
".docz/",
"public/",
"src/generated",
"_schema.json",
"package.json",
"src/types.tsx"
]
},
"javascript": {
"jsxRuntime": "reactClassic"
}
}
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file added frontend-styleguide/fonts/JetBrainsMono.ttf
Binary file not shown.
76 changes: 76 additions & 0 deletions frontend-styleguide/package.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,76 @@
{
"name": "@python-italia/pycon-styleguide",
"version": "0.1.210",
"main": "dist/index.js",
"module": "dist/index.esm.js",
"types": "dist/index.d.ts",
"exports": {
".": "./dist/index.js",
"./style": "./dist/index.css",
"./custom-style": "./dist/custom-style.css",
"./config-parts": "./dist/config-parts.js",
"./icons": "./dist/icons/index.js",
"./illustrations": "./dist/illustrations/index.js"
},
"scripts": {
"test": "jest",
"test:watch": "jest --watch",
"storybook": "start-storybook -p 6006",
"storybook:export": "build-storybook",
"build": "rollup -c",
"build:watch": "rollup -c -w",
"prepublishOnly": "rm -rf dist/ && pnpm run build"
},
"peerDependencies": {
"clsx": "^1.1.1",
"date-fns": "^2.28.0",
"react": ">=16.8.0",
"react-dom": ">=16.8.0",
"react-use": "^17.3.2"
},
"devDependencies": {
"@babel/core": "^7.24.5",
"@rollup/plugin-commonjs": "^21.1.0",
"@rollup/plugin-node-resolve": "^13.3.0",
"@storybook/addon-essentials": "^6.5.16",
"@storybook/addon-postcss": "^2.0.0",
"@storybook/react": "^6.5.16",
"@tailwindcss/typography": "^0.5.13",
"@testing-library/jest-dom": "^5.17.0",
"@testing-library/react": "^12.1.5",
"@types/bluebird": "^3.5.42",
"@types/jest": "^27.5.2",
"@types/node": "^20.12.11",
"@types/react": "^17.0.80",
"@types/react-dom": "^17.0.25",
"autoprefixer": "^10.4.19",
"babel-loader": "^8.3.0",
"babel-preset-react-app": "^10.0.1",
"identity-obj-proxy": "^3.0.0",
"jest": "^27.5.1",
"postcss": "^8.4.38",
"prettier": "^2.8.8",
"prop-types": "^15.8.1",
"react": "^18.3.1",
"react-dom": "^18.3.1",
"rollup": "^2.79.1",
"rollup-plugin-styles": "^4.0.0",
"rollup-plugin-terser": "^7.0.2",
"rollup-plugin-typescript2": "^0.34.1",
"tailwindcss": "^3.4.3",
"tailwindcss-blend-mode": "^1.0.0",
"ts-jest": "^27.1.5",
"ts-toolbelt": "^9.6.0",
"tslib": "^2.6.2",
"typescript": "^4.9.5",
"webpack": "^5.91.0"
},
"dependencies": {
"clsx": "^1.2.1",
"date-fns": "^2.30.0",
"framer-motion": "^11.1.9",
"react-intl": "^6.6.6",
"react-text-transition": "^1.3.0",
"react-use": "^17.5.0"
}
}
Loading
Loading