Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: transform to monorepo and prepare for web components #75

Merged
merged 36 commits into from
Jan 21, 2024
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
Show all changes
36 commits
Select commit Hold shift + click to select a range
691c30d
move existing code to legacy folder
rschlaefli May 2, 2023
d612a0e
current progress
rschlaefli May 2, 2023
b22baa8
more trials
rschlaefli May 2, 2023
3c9c042
move design system to packages dir
rschlaefli May 2, 2023
1d8e12a
reorganize tag folder
rschlaefli May 2, 2023
9d68adf
further reorg
rschlaefli May 2, 2023
680a0fb
move design system to react peer dep, remove husky
rschlaefli May 2, 2023
6f232c0
fix using volta extends
rschlaefli May 2, 2023
9ea3903
optimize build process with rimraf
rschlaefli May 2, 2023
c2d98b2
progress
rschlaefli May 2, 2023
6787f81
simple approach
rschlaefli May 3, 2023
6b8e19a
improvements
rschlaefli May 3, 2023
d439af2
simplify build of tag component
rschlaefli May 3, 2023
4e272f5
add files to package.json to upload dist to npm
rschlaefli May 3, 2023
2aa281e
move custom element tag
rschlaefli May 3, 2023
9139091
start work on react tag package
rschlaefli May 3, 2023
da3db81
working react build
rschlaefli May 3, 2023
34c1fec
cleanup tailwind
rschlaefli May 3, 2023
9313a79
optimize react tag
rschlaefli May 3, 2023
75c92a7
add a parcel resolver that remaps react to preact
rschlaefli May 3, 2023
fbe3cd6
working react web component
rschlaefli May 3, 2023
e617939
need to bundle node modules to work, as dep of dep is not aliased in …
rschlaefli May 3, 2023
f525277
bundle only the design system but none of its deps to allow them to b…
rschlaefli May 3, 2023
0a8d76a
wip: create packages for react and custom header components
sjschlapbach May 3, 2023
33b571d
fix: ensure that demo for custom header components works
sjschlapbach May 3, 2023
6cf2ca5
chore: fix prettier configuration and code formatting
sjschlapbach May 3, 2023
3c210ab
Merge branch 'main' of https://github.com/uzh-bf/design-system into W…
rschlaefli Nov 22, 2023
c6a0732
remove theme provider
rschlaefli Nov 22, 2023
f5e2dd6
fixed dependencies for build
rschlaefli Nov 22, 2023
c3bb2e5
fix ci scripts
rschlaefli Nov 22, 2023
6ed51f6
Merge branch 'dev' of https://github.com/uzh-bf/design-system into We…
rschlaefli Jan 21, 2024
364f5c4
publish only on tags
rschlaefli Jan 21, 2024
163ad3b
fix: postcss js
rschlaefli Jan 21, 2024
79d066b
setup turbo
rschlaefli Jan 21, 2024
3fb8b14
next dir irrelevant in turbo
rschlaefli Jan 21, 2024
550374a
add dev command for design system only
rschlaefli Jan 21, 2024
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
Next Next commit
move existing code to legacy folder
  • Loading branch information
rschlaefli committed May 2, 2023
commit 691c30dac64966ffd97882f85bfbbe7613a9c201
18 changes: 0 additions & 18 deletions dts.config.js

This file was deleted.

File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
31 changes: 31 additions & 0 deletions legacy/dts.config.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
const postcss = require('rollup-plugin-postcss')
const autoprefixer = require('autoprefixer')
// const cssnano = require('cssnano')
const tailwindcss = require('tailwindcss')
const tailwindcssNesting = require('tailwindcss/nesting')
const alias = require('@rollup/plugin-alias')
const html = require('@rollup/plugin-html')

module.exports = {
rollup(config, options) {
config.plugins.push(
html({
include: '**/*.html',
}),
postcss({
plugins: [tailwindcssNesting(), tailwindcss(), autoprefixer()],
inject: false,
extract: true,
}),
alias({
entries: [
{ find: 'react', replacement: 'preact/compat' },
{ find: 'react-dom/test-utils', replacement: 'preact/test-utils' },
{ find: 'react-dom', replacement: 'preact/compat' },
{ find: 'react/jsx-runtime', replacement: 'preact/jsx-runtime' },
],
})
)
return config
},
}
70 changes: 68 additions & 2 deletions package-lock.json → legacy/package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

8 changes: 6 additions & 2 deletions package.json → legacy/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@
"build:dts": "dts build --entry src/index.ts --entry src/constants.js",
"build:copy": "node src/copy.js",
"lint": "dts lint",
"start": "dts watch",
"size": "size-limit",
"dev": "ladle serve",
"deploy": "ladle build",
Expand Down Expand Up @@ -53,6 +54,8 @@
],
"devDependencies": {
"@ladle/react": "2.4.5",
"@rollup/plugin-alias": "^5.0.0",
"@rollup/plugin-html": "^1.0.2",
"@size-limit/preset-small-lib": "7.0.8",
"@tailwindcss/aspect-ratio": "0.4.2",
"@tailwindcss/forms": "0.5.3",
Expand All @@ -61,6 +64,7 @@
"@tsconfig/create-react-app": "1.0.3",
"@tsconfig/recommended": "1.0.1",
"@types/node": "^18.11.9",
"@types/preact-custom-element": "^4.0.1",
"@types/react": "^18.0.15",
"@types/react-dom": "^18.0.6",
"autoprefixer": "10.4.13",
Expand Down Expand Up @@ -89,8 +93,6 @@
"@fortawesome/react-fontawesome": "^0.2.0",
"dayjs": "^1.0.0",
"formik": "^2.2.9",
"react": "^18.2.0",
"react-dom": "^18.2.0",
"tailwind-merge": "^1.8.1",
"yup": "^1.0.0"
},
Expand All @@ -108,6 +110,8 @@
"@radix-ui/react-tabs": "1.0.1",
"@radix-ui/react-toast": "1.1.2",
"@radix-ui/react-tooltip": "1.0.2",
"preact": "10.13.2",
"preact-custom-element": "4.2.1",
"react-countdown-circle-timer": "3.1.0"
}
}
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
4 changes: 4 additions & 0 deletions legacy/src/WCTag.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
import register from 'preact-custom-element'
import { Tag as BFTag } from './Tag'

register(BFTag, 'x-tag', ['label'], { shadow: false })
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
21 changes: 21 additions & 0 deletions legacy/src/template.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
<!DOCTYPE html>
<html>
<head>
<title>Parcel Sandbox</title>
<meta charset="UTF-8" />
<link rel="stylesheet" href="src/styles.css">
<script src="src/index.ts"></script>
</head>

<body>
<div id="app">
<div id="container" class="container">
<x-button text="hello" onclick="console.log('hello world')"></x-button>
<x-countdown duration="60"></x-countdown>
<x-bf-countdown countdown-duration="60"></x-bf-countdown>
<x-collapsible content="hello world"></x-collapsible>
</div>
</div>
</div>
</body>
</html>
File renamed without changes.
File renamed without changes.
File renamed without changes.