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 rn atomic css #1788

Open
wants to merge 104 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
104 commits
Select commit Hold shift + click to select a range
68434b2
[feat]rn-atomic-css
CommanderXL Nov 8, 2024
a88cdd9
[fix]lint
CommanderXL Nov 8, 2024
f9ab9c1
[feat]add empty rule transform
CommanderXL Nov 14, 2024
e39ec8a
[feat]add warn&errors
CommanderXL Nov 14, 2024
450f76b
[feat]add shadow rule
CommanderXL Nov 14, 2024
777dcca
[fix]lint
CommanderXL Nov 14, 2024
c414f17
[feat]add more rules
CommanderXL Nov 19, 2024
ff99449
update
CommanderXL Nov 21, 2024
7e90afe
[feat]support hover pseudo class
CommanderXL Nov 22, 2024
386c0ff
[feat]add hasUnoCSS for template compiler
CommanderXL Nov 22, 2024
11ddc5b
[feat]add new rule and upgrade unocss version
CommanderXL Dec 3, 2024
2034a02
[update]
CommanderXL Dec 3, 2024
372ab91
[feat]support modern rgb/hsl grammer
CommanderXL Dec 3, 2024
99dd414
[update]extra code
CommanderXL Dec 5, 2024
7c9f994
feat: upgrade unocss
mater1996 Dec 5, 2024
27c13ac
[fix]formatValue
CommanderXL Dec 6, 2024
3da4fee
fix: preset
mater1996 Dec 10, 2024
f898f6b
fix: type
mater1996 Dec 10, 2024
792cde2
Merge branch 'feat-rn-atomic-css' of github.com:didi/mpx into feat-rn…
mater1996 Dec 10, 2024
cc0cbf8
fix: unocss ready
mater1996 Dec 10, 2024
13fd97d
fix: uno存储问题
mater1996 Dec 10, 2024
f3789ca
fix: mpx instance
mater1996 Dec 17, 2024
d86b308
fix: remove debugg
mater1996 Dec 17, 2024
dc50729
fix: lint
mater1996 Dec 17, 2024
57ce2f8
fix: remove console
mater1996 Dec 17, 2024
c933e3e
Merge pull request #1741 from didi/feat-rn-atomic-css-upgrade
CommanderXL Dec 17, 2024
320ace5
fix: minimatch
mater1996 Dec 17, 2024
abf1b6f
feat: preset
mater1996 Dec 18, 2024
ea891f8
feat: preset
mater1996 Dec 20, 2024
e238722
[update]add new rules
CommanderXL Dec 23, 2024
dbccab7
fix: rules
mater1996 Dec 23, 2024
f5f4160
fix: console
mater1996 Dec 23, 2024
dc6373f
[update]optimize combine preset
CommanderXL Dec 23, 2024
b5e03c4
fix: divide support
mater1996 Dec 23, 2024
c4c9825
[feat]support dark mode
CommanderXL Dec 24, 2024
8d21de4
[update]typograph rule
CommanderXL Dec 24, 2024
a3dacd4
[update]border rule
CommanderXL Dec 24, 2024
30e96f7
fix: preset
mater1996 Dec 24, 2024
f0adcbb
fix: transform
mater1996 Dec 24, 2024
eaaf945
fix: transform
mater1996 Dec 24, 2024
c5cbd43
fix: format
mater1996 Dec 25, 2024
7e1327e
fix: support rule
mater1996 Dec 25, 2024
8161d1b
fix: wx build error
mater1996 Dec 26, 2024
77e9d1a
fix: import
mater1996 Dec 26, 2024
b918849
fix: 移除transform从一些工具类
mater1996 Dec 26, 2024
dd43b07
[update]preset
CommanderXL Dec 26, 2024
aa2a250
[merge]merge from master
CommanderXL Dec 26, 2024
9466418
Merge branch 'feat-rn-atomic-css' of github.com:didi/mpx into feat-rn…
CommanderXL Dec 26, 2024
db17b59
[fix]
CommanderXL Dec 26, 2024
45e2202
Merge branch 'feat-rn-atomic-css' of github.com:didi/mpx into feat-rn…
CommanderXL Dec 26, 2024
dc6a12f
[fix]merge code from master
CommanderXL Dec 26, 2024
01b76bf
Merge branch 'feat-rn-atomic-css' of github.com:didi/mpx into feat-rn…
CommanderXL Dec 26, 2024
6d7a499
[fix]some method
CommanderXL Dec 26, 2024
769f7c7
[fix]some error
CommanderXL Dec 26, 2024
ce5fbd3
[fix]lint
CommanderXL Dec 26, 2024
5be0325
[update]the order of unocss and app css
CommanderXL Dec 26, 2024
e14884b
little adjust
CommanderXL Dec 26, 2024
f9b4b40
Merge pull request #1767 from didi/feat-uno-rn-preset
CommanderXL Dec 26, 2024
c66de72
[update]clear code
CommanderXL Dec 26, 2024
459165e
[update]decoration & filter
CommanderXL Dec 26, 2024
c6dbef1
[update]add font theme
CommanderXL Dec 27, 2024
8d38f4d
feat: docs
mater1996 Jan 2, 2025
3f87e59
Merge branch 'feat-rn-atomic-css' of github.com:didi/mpx into feat-rn…
mater1996 Jan 2, 2025
ff32e25
[merge]merge from master
CommanderXL Jan 2, 2025
a00c069
Merge branch 'feat-rn-atomic-css' of github.com:didi/mpx into feat-rn…
CommanderXL Jan 2, 2025
43219d9
fix: docs
mater1996 Jan 3, 2025
e3e4dac
t push
mater1996 Jan 3, 2025
1091497
fix: docs
mater1996 Jan 3, 2025
3fc9efa
[fix]formatValue
CommanderXL Jan 3, 2025
f4132e9
[feat]support variant check
CommanderXL Jan 3, 2025
b79ef77
Merge branch 'feat-rn-atomic-css' of github.com:didi/mpx into feat-rn…
CommanderXL Jan 3, 2025
5123832
[fix]some edge case
CommanderXL Jan 3, 2025
810a235
feat: unocss order
mater1996 Jan 6, 2025
0b0b38b
[feat]compatiable for legacy color
CommanderXL Jan 6, 2025
4bea9bb
fix: preflights
mater1996 Jan 6, 2025
7abaa37
fix: remove console
mater1996 Jan 6, 2025
c9c48ab
[feat]using blocklist for rules
CommanderXL Jan 6, 2025
3d9bb0c
fix: conflict
mater1996 Jan 6, 2025
35ac85b
fix: rules
mater1996 Jan 6, 2025
962b83b
fix: var
mater1996 Jan 6, 2025
976fc02
fix: uno
mater1996 Jan 6, 2025
d54aaed
fix: remove boxshadow
mater1996 Jan 6, 2025
a8cb2d3
Merge pull request #1795 from didi/feat-unocss-order-v2
CommanderXL Jan 6, 2025
f99d366
fix: build
mater1996 Jan 6, 2025
8c50fdc
[fix]some utils
CommanderXL Jan 6, 2025
08d75f0
Merge branch 'feat-rn-atomic-css' of github.com:didi/mpx into feat-rn…
CommanderXL Jan 6, 2025
d641c3d
[optimize]filer rule
CommanderXL Jan 6, 2025
bf3df99
[optimize]text-decoration & blocklist
CommanderXL Jan 6, 2025
3a00f88
[update]add docs
CommanderXL Jan 7, 2025
6c8fbed
fix: remove docs uno
mater1996 Jan 7, 2025
33458ef
Merge branch 'feat-rn-atomic-css' of github.com:didi/mpx into feat-rn…
mater1996 Jan 7, 2025
c9ea2e3
fix: docs
mater1996 Jan 7, 2025
7cceee9
[optimize]getUnoClassMap
CommanderXL Jan 7, 2025
1232ba5
Merge branch 'feat-rn-atomic-css' of github.com:didi/mpx into feat-rn…
CommanderXL Jan 7, 2025
0efa7f2
[docs]add docs
CommanderXL Jan 7, 2025
74f0b63
[feat]border rule
CommanderXL Jan 7, 2025
74eb854
Merge branch 'feat-rn-atomic-css' of github.com:didi/mpx into feat-rn…
CommanderXL Jan 7, 2025
d75716f
[docs]
CommanderXL Jan 7, 2025
54a0264
Merge branch 'feat-rn-atomic-css' of github.com:didi/mpx into feat-rn…
CommanderXL Jan 7, 2025
c5d09d7
[docs]
CommanderXL Jan 7, 2025
cc5e287
fix: docs
mater1996 Jan 7, 2025
248e0f4
fix: docs
mater1996 Jan 7, 2025
adefb09
Merge pull request #1798 from didi/feat-rn-atomic-css-docs
CommanderXL Jan 7, 2025
a3fedee
fix: docs
mater1996 Jan 7, 2025
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: 1 addition & 1 deletion docs-vuepress/.vuepress/config.js
Original file line number Diff line number Diff line change
Expand Up @@ -119,7 +119,7 @@ const sidebar = {
{ title: '小程序跨端组件库 Mpx-cube-ui 开源啦', path: 'mpx-cube-ui' },
{ title: 'Mpx-cli 插件化改造', path: 'mpx-cli-next' },
{ title: 'Mpx 小程序单元测试能力建设与实践', path: 'unit-test'}
]
],
}

const nav = [
Expand Down
28 changes: 28 additions & 0 deletions docs-vuepress/.vuepress/theme/global-components/ColorsPalette.vue
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
<template>
<div class="my-8">
<div v-for="color in colors" :key="color">
<div class="relative mb-3 mt-6">
<span>{{ color }}</span>
</div>
<div class="flex gap-2 mb-2 overflow-y-auto">
<SingleColor v-for="level in levels" :key="level" :color="`bg-${color}-${level}`" />
</div>
</div>
</div>
</template>

<script>

export default {
data() {
return {
levels: [50, 100, 200, 300, 400, 500, 600, 700, 800, 900],
colors: [
'pink', 'rose', 'red', 'orange', 'yellow', 'amber', 'lime', 'green', 'emerald', 'teal',
'cyan', 'sky', 'blue', 'indigo', 'purple', 'violet', 'fuchsia', 'gray', 'slate', 'stone',
'neutral', 'zinc', 'light', 'dark',
]
};
}
};
</script>
39 changes: 39 additions & 0 deletions docs-vuepress/.vuepress/theme/global-components/SingleColor.vue
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
<script>
// import config from 'windicss/defaultConfig'
export default {
name: 'SingleColor',
props: {
color: {
type: String,
default: ''
}
},
methods: {
camelize(str) {
const arr = str.split('-')
const capital = arr.map((item, index) => index ? item.charAt(0).toUpperCase() + item.slice(1).toLowerCase() : item.toLowerCase())
const capitalString = capital.join('')
return capitalString
}
},
computed: {
level() {
return this.color.split(/-/).slice(-1)[0]
},
hex() {
// return config.theme.colors[this.camelize(this.color)]?.[+this.level]
}
}
}
</script>
<template>
<div>
<div class="w-14 h-14 rounded" :class="color" />
<div class="font-bold text-sm">
{{ level }}
</div>
<div class="opacity-50 font-mono text-xs -mt-1">
{{ hex }}
</div>
</div>
</template>
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ Mpx以微信增强DSL为基础,支持跨端输出至多端小程序、web和
new MpxwebpackPlugin({
// mode为mpx编译的目标平台,可选值有(wx|ali|swan|qq|tt|jd|web|ios|android|harmony)
mode: 'ali',
// srcMode为mpx编译的源码平台,目前仅支持wx
// srcMode为mpx编译的源码平台,目前仅支持wx
srcMode: 'wx'
})
```
Expand Down
Loading
Loading