arche 0.3.0 → 0.3.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.github/workflows/nodejs.yml +1 -1
- package/README.md +1 -1
- package/es.js +4 -4
- package/index.js +4 -4
- package/index.mjs +4 -4
- package/package.json +1 -1
- package/test.js +8 -8
package/README.md
CHANGED
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
> Arche (/ˈɑːrki/; Ancient Greek: ἀρχή) is a Greek word with primary senses "beginning", "origin" or "source of action" (ἐξ' ἀρχῆς: from the beginning, οr ἐξ' ἀρχῆς λόγος: the original argument), and later "first principle" or "element". ([wikipedia](https://en.wikipedia.org/wiki/Arche))
|
|
4
4
|
|
|
5
5
|

|
|
6
|
-
[](https://codecov.io/gh/
|
|
6
|
+
[](https://codecov.io/gh/richytong/arche)
|
|
7
7
|
|
|
8
8
|
HTML as JavaScript.
|
|
9
9
|
|
package/es.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* Arche v0.
|
|
2
|
+
* Arche v0.3.1
|
|
3
3
|
* https://github.com/richytong/arche
|
|
4
4
|
* (c) 2020-2021 Richard Tong
|
|
5
5
|
* Arche may be freely distributed under the MIT license.
|
|
@@ -223,7 +223,7 @@ const Arche = function (creator, options = {}) {
|
|
|
223
223
|
return creatorCreateElement(creator, type, arg0, arg1)
|
|
224
224
|
}
|
|
225
225
|
const { css, ...props } = arg0
|
|
226
|
-
return creatorCreateElement(creator, styled[type](css), props, arg1)
|
|
226
|
+
return creatorCreateElement(creator, styled[type]([css]), props, arg1)
|
|
227
227
|
}
|
|
228
228
|
|
|
229
229
|
if (arg1 == null) {
|
|
@@ -231,14 +231,14 @@ const Arche = function (creator, options = {}) {
|
|
|
231
231
|
return creatorCreateElement(creator, type, arg0, [])
|
|
232
232
|
}
|
|
233
233
|
const { css, ...props } = arg0
|
|
234
|
-
return creatorCreateElement(creator, styled[type](css), props, [])
|
|
234
|
+
return creatorCreateElement(creator, styled[type]([css]), props, [])
|
|
235
235
|
}
|
|
236
236
|
|
|
237
237
|
if (arg0.css == null) {
|
|
238
238
|
return creatorCreateElement(creator, type, arg0, [arg1])
|
|
239
239
|
}
|
|
240
240
|
const { css, ...props } = arg0
|
|
241
|
-
return creatorCreateElement(creator, styled[type](css), props, [arg1])
|
|
241
|
+
return creatorCreateElement(creator, styled[type]([css]), props, [arg1])
|
|
242
242
|
}
|
|
243
243
|
|
|
244
244
|
const rootElement = (
|
package/index.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* Arche v0.
|
|
2
|
+
* Arche v0.3.1
|
|
3
3
|
* https://github.com/richytong/arche
|
|
4
4
|
* (c) 2020-2021 Richard Tong
|
|
5
5
|
* Arche may be freely distributed under the MIT license.
|
|
@@ -229,7 +229,7 @@ const Arche = function (creator, options = {}) {
|
|
|
229
229
|
return creatorCreateElement(creator, type, arg0, arg1)
|
|
230
230
|
}
|
|
231
231
|
const { css, ...props } = arg0
|
|
232
|
-
return creatorCreateElement(creator, styled[type](css), props, arg1)
|
|
232
|
+
return creatorCreateElement(creator, styled[type]([css]), props, arg1)
|
|
233
233
|
}
|
|
234
234
|
|
|
235
235
|
if (arg1 == null) {
|
|
@@ -237,14 +237,14 @@ const Arche = function (creator, options = {}) {
|
|
|
237
237
|
return creatorCreateElement(creator, type, arg0, [])
|
|
238
238
|
}
|
|
239
239
|
const { css, ...props } = arg0
|
|
240
|
-
return creatorCreateElement(creator, styled[type](css), props, [])
|
|
240
|
+
return creatorCreateElement(creator, styled[type]([css]), props, [])
|
|
241
241
|
}
|
|
242
242
|
|
|
243
243
|
if (arg0.css == null) {
|
|
244
244
|
return creatorCreateElement(creator, type, arg0, [arg1])
|
|
245
245
|
}
|
|
246
246
|
const { css, ...props } = arg0
|
|
247
|
-
return creatorCreateElement(creator, styled[type](css), props, [arg1])
|
|
247
|
+
return creatorCreateElement(creator, styled[type]([css]), props, [arg1])
|
|
248
248
|
}
|
|
249
249
|
|
|
250
250
|
const rootElement = (
|
package/index.mjs
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* Arche v0.
|
|
2
|
+
* Arche v0.3.1
|
|
3
3
|
* https://github.com/richytong/arche
|
|
4
4
|
* (c) 2020-2021 Richard Tong
|
|
5
5
|
* Arche may be freely distributed under the MIT license.
|
|
@@ -223,7 +223,7 @@ const Arche = function (creator, options = {}) {
|
|
|
223
223
|
return creatorCreateElement(creator, type, arg0, arg1)
|
|
224
224
|
}
|
|
225
225
|
const { css, ...props } = arg0
|
|
226
|
-
return creatorCreateElement(creator, styled[type](css), props, arg1)
|
|
226
|
+
return creatorCreateElement(creator, styled[type]([css]), props, arg1)
|
|
227
227
|
}
|
|
228
228
|
|
|
229
229
|
if (arg1 == null) {
|
|
@@ -231,14 +231,14 @@ const Arche = function (creator, options = {}) {
|
|
|
231
231
|
return creatorCreateElement(creator, type, arg0, [])
|
|
232
232
|
}
|
|
233
233
|
const { css, ...props } = arg0
|
|
234
|
-
return creatorCreateElement(creator, styled[type](css), props, [])
|
|
234
|
+
return creatorCreateElement(creator, styled[type]([css]), props, [])
|
|
235
235
|
}
|
|
236
236
|
|
|
237
237
|
if (arg0.css == null) {
|
|
238
238
|
return creatorCreateElement(creator, type, arg0, [arg1])
|
|
239
239
|
}
|
|
240
240
|
const { css, ...props } = arg0
|
|
241
|
-
return creatorCreateElement(creator, styled[type](css), props, [arg1])
|
|
241
|
+
return creatorCreateElement(creator, styled[type]([css]), props, [arg1])
|
|
242
242
|
}
|
|
243
243
|
|
|
244
244
|
const rootElement = (
|
package/package.json
CHANGED
package/test.js
CHANGED
|
@@ -73,16 +73,16 @@ describe('Arche', () => {
|
|
|
73
73
|
},
|
|
74
74
|
}
|
|
75
75
|
|
|
76
|
-
const
|
|
76
|
+
const get0 = value => value[0]
|
|
77
77
|
|
|
78
78
|
const styled = {
|
|
79
|
-
h1:
|
|
80
|
-
h2:
|
|
81
|
-
div:
|
|
82
|
-
p:
|
|
83
|
-
b:
|
|
84
|
-
span:
|
|
85
|
-
article:
|
|
79
|
+
h1: get0,
|
|
80
|
+
h2: get0,
|
|
81
|
+
div: get0,
|
|
82
|
+
p: get0,
|
|
83
|
+
b: get0,
|
|
84
|
+
span: get0,
|
|
85
|
+
article: get0,
|
|
86
86
|
}
|
|
87
87
|
|
|
88
88
|
const rootElement = Arche(mockReact, { styled })
|