@jxsuite/ui 0.0.0

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.
@@ -0,0 +1,208 @@
1
+ {
2
+ "$schema": "https://jxsuite.com/schema/v1",
3
+ "$id": "StylebookIcon",
4
+ "tagName": "main",
5
+ "$elements": [
6
+ {
7
+ "$ref": "../components/jx-icon.json"
8
+ }
9
+ ],
10
+ "state": {
11
+ "weights": ["regular", "bold", "fill"],
12
+ "names": [
13
+ "align-bottom",
14
+ "align-bottom-simple",
15
+ "align-center-horizontal",
16
+ "align-center-horizontal-simple",
17
+ "align-center-vertical",
18
+ "align-left",
19
+ "align-right",
20
+ "align-top",
21
+ "align-top-simple",
22
+ "arrow-down",
23
+ "arrow-elbow-left-up",
24
+ "arrow-left",
25
+ "arrow-right",
26
+ "arrow-square-out",
27
+ "arrow-u-up-left",
28
+ "arrow-u-up-right",
29
+ "arrow-up",
30
+ "arrows-clockwise",
31
+ "arrows-horizontal",
32
+ "arrows-out",
33
+ "arrows-out-line-horizontal",
34
+ "arrows-out-line-vertical",
35
+ "arrows-vertical",
36
+ "brackets-curly",
37
+ "browser",
38
+ "caret-down",
39
+ "caret-left",
40
+ "caret-right",
41
+ "caret-up",
42
+ "chat-circle",
43
+ "check",
44
+ "clipboard",
45
+ "clock-counter-clockwise",
46
+ "code",
47
+ "columns",
48
+ "copy",
49
+ "cube",
50
+ "database",
51
+ "dots-three",
52
+ "dots-three-vertical",
53
+ "download-simple",
54
+ "export",
55
+ "eye",
56
+ "eye-slash",
57
+ "file",
58
+ "file-code",
59
+ "file-text",
60
+ "flip-vertical",
61
+ "floppy-disk",
62
+ "folder",
63
+ "folder-open",
64
+ "frame-corners",
65
+ "gear",
66
+ "gear-six",
67
+ "git-branch",
68
+ "globe",
69
+ "grid-four",
70
+ "image",
71
+ "info",
72
+ "lightning",
73
+ "link",
74
+ "list",
75
+ "list-bullets",
76
+ "magnifying-glass",
77
+ "minus",
78
+ "paint-brush",
79
+ "paper-plane-tilt",
80
+ "paperclip",
81
+ "pencil-simple",
82
+ "play",
83
+ "plus",
84
+ "question",
85
+ "rectangle",
86
+ "rows",
87
+ "share-network",
88
+ "sidebar-simple",
89
+ "sliders-horizontal",
90
+ "sparkle",
91
+ "spinner",
92
+ "square",
93
+ "stack",
94
+ "stop",
95
+ "tag",
96
+ "text-aa",
97
+ "text-align-center",
98
+ "text-align-justify",
99
+ "text-align-left",
100
+ "text-align-right",
101
+ "text-b",
102
+ "text-italic",
103
+ "text-strikethrough",
104
+ "text-subscript",
105
+ "text-superscript",
106
+ "text-underline",
107
+ "translate",
108
+ "trash",
109
+ "upload-simple",
110
+ "warning",
111
+ "warning-circle",
112
+ "x"
113
+ ]
114
+ },
115
+ "style": {
116
+ "fontFamily": "var(--jx-font-sans)",
117
+ "fontSize": "var(--jx-text-md)",
118
+ "color": "var(--jx-fg)",
119
+ "background": "var(--jx-bg)",
120
+ "padding": "var(--jx-space-6)",
121
+ "& > h1": {
122
+ "fontSize": "var(--jx-text-lg)",
123
+ "fontWeight": "600",
124
+ "margin": "0 0 var(--jx-space-5)"
125
+ },
126
+ "& > ul": {
127
+ "display": "grid",
128
+ "gridTemplateColumns": "repeat(auto-fill, minmax(180px, 1fr))",
129
+ "gap": "var(--jx-space-3)",
130
+ "listStyle": "none",
131
+ "margin": "0",
132
+ "padding": "0"
133
+ },
134
+ "& > ul > li": {
135
+ "display": "flex",
136
+ "alignItems": "center",
137
+ "gap": "var(--jx-space-3)",
138
+ "padding": "var(--jx-space-2) var(--jx-space-3)",
139
+ "border": "1px solid var(--jx-border)",
140
+ "borderRadius": "var(--jx-radius-sm)",
141
+ "background": "var(--jx-bg-panel)"
142
+ },
143
+ "& code": {
144
+ "fontFamily": "var(--jx-font-mono)",
145
+ "fontSize": "var(--jx-text-sm)",
146
+ "color": "var(--jx-fg-dim)"
147
+ }
148
+ },
149
+ "children": [
150
+ {
151
+ "tagName": "h1",
152
+ "textContent": "jx-icon"
153
+ },
154
+ {
155
+ "tagName": "p",
156
+ "textContent": "Every glyph the kit ships, at regular weight. A label makes an icon announce itself; without one it is decorative."
157
+ },
158
+ {
159
+ "tagName": "ul",
160
+ "children": [
161
+ {
162
+ "$prototype": "Array",
163
+ "items": {
164
+ "$ref": "#/state/names"
165
+ },
166
+ "key": {
167
+ "$ref": "$map/item"
168
+ },
169
+ "map": {
170
+ "tagName": "li",
171
+ "children": [
172
+ {
173
+ "tagName": "jx-icon",
174
+ "$props": {
175
+ "name": {
176
+ "$ref": "$map/item"
177
+ }
178
+ }
179
+ },
180
+ {
181
+ "tagName": "jx-icon",
182
+ "$props": {
183
+ "name": {
184
+ "$ref": "$map/item"
185
+ },
186
+ "weight": "bold"
187
+ }
188
+ },
189
+ {
190
+ "tagName": "jx-icon",
191
+ "$props": {
192
+ "name": {
193
+ "$ref": "$map/item"
194
+ },
195
+ "weight": "fill"
196
+ }
197
+ },
198
+ {
199
+ "tagName": "code",
200
+ "textContent": "${$map.item}"
201
+ }
202
+ ]
203
+ }
204
+ }
205
+ ]
206
+ }
207
+ ]
208
+ }
@@ -0,0 +1,221 @@
1
+ {
2
+ "$schema": "https://jxsuite.com/schema/v1",
3
+ "$id": "StylebookMenuItem",
4
+ "tagName": "main",
5
+ "$elements": [
6
+ {
7
+ "$ref": "../components/jx-icon.json"
8
+ },
9
+ {
10
+ "$ref": "../components/jx-menu-item.json"
11
+ }
12
+ ],
13
+ "state": {
14
+ "rows": [
15
+ {
16
+ "id": "plain",
17
+ "title": "Plain",
18
+ "chord": "",
19
+ "requires": "",
20
+ "disabled": false,
21
+ "destructive": false,
22
+ "checked": "",
23
+ "haspopup": false,
24
+ "enabled": true,
25
+ "noChord": true,
26
+ "noPopup": true
27
+ },
28
+ {
29
+ "id": "chord",
30
+ "title": "With a chord",
31
+ "chord": "⌘K",
32
+ "requires": "",
33
+ "disabled": false,
34
+ "destructive": false,
35
+ "checked": "",
36
+ "haspopup": false,
37
+ "enabled": true,
38
+ "noChord": false,
39
+ "noPopup": true
40
+ },
41
+ {
42
+ "id": "disabled",
43
+ "title": "Disabled",
44
+ "chord": "⌘V",
45
+ "requires": "something on the clipboard",
46
+ "disabled": true,
47
+ "destructive": false,
48
+ "checked": "",
49
+ "haspopup": false,
50
+ "enabled": false,
51
+ "noChord": false,
52
+ "noPopup": true
53
+ },
54
+ {
55
+ "id": "checked",
56
+ "title": "Checked",
57
+ "chord": "",
58
+ "requires": "",
59
+ "disabled": false,
60
+ "destructive": false,
61
+ "checked": "true",
62
+ "haspopup": false,
63
+ "enabled": true,
64
+ "noChord": true,
65
+ "noPopup": true
66
+ },
67
+ {
68
+ "id": "unchecked",
69
+ "title": "Unchecked",
70
+ "chord": "",
71
+ "requires": "",
72
+ "disabled": false,
73
+ "destructive": false,
74
+ "checked": "false",
75
+ "haspopup": false,
76
+ "enabled": true,
77
+ "noChord": true,
78
+ "noPopup": true
79
+ },
80
+ {
81
+ "id": "submenu",
82
+ "title": "Owns a submenu",
83
+ "chord": "",
84
+ "requires": "",
85
+ "disabled": false,
86
+ "destructive": false,
87
+ "checked": "",
88
+ "haspopup": true,
89
+ "enabled": true,
90
+ "noChord": true,
91
+ "noPopup": false
92
+ },
93
+ {
94
+ "id": "destructive",
95
+ "title": "Destructive",
96
+ "chord": "⌫",
97
+ "requires": "",
98
+ "disabled": false,
99
+ "destructive": true,
100
+ "checked": "",
101
+ "haspopup": false,
102
+ "enabled": true,
103
+ "noChord": false,
104
+ "noPopup": true
105
+ }
106
+ ]
107
+ },
108
+ "style": {
109
+ "fontFamily": "var(--jx-font-sans)",
110
+ "fontSize": "var(--jx-text-md)",
111
+ "color": "var(--jx-fg)",
112
+ "background": "var(--jx-bg)",
113
+ "padding": "var(--jx-space-6)",
114
+ "minHeight": "100vh",
115
+ "& > h1": {
116
+ "fontSize": "var(--jx-text-lg)",
117
+ "fontWeight": "600",
118
+ "margin": "0 0 var(--jx-space-5)"
119
+ },
120
+ "& > p": {
121
+ "color": "var(--jx-fg-dim)",
122
+ "margin": "0 0 var(--jx-space-5)"
123
+ },
124
+ "& > [role=\"menu\"]": {
125
+ "display": "flex",
126
+ "flexDirection": "column",
127
+ "gap": "var(--jx-space-1)",
128
+ "width": "280px",
129
+ "padding": "var(--jx-space-2)",
130
+ "background": "var(--jx-bg-overlay)",
131
+ "border": "1px solid var(--jx-border-strong)",
132
+ "borderRadius": "var(--jx-radius-md)"
133
+ }
134
+ },
135
+ "children": [
136
+ {
137
+ "tagName": "h1",
138
+ "textContent": "jx-menu-item"
139
+ },
140
+ {
141
+ "tagName": "p",
142
+ "textContent": "Every state a row can be in, laid out in a static list so each is visible at once. A row is disabled, never absent; its reason is its tooltip."
143
+ },
144
+ {
145
+ "tagName": "div",
146
+ "attributes": {
147
+ "role": "menu",
148
+ "aria-label": "Row states"
149
+ },
150
+ "children": [
151
+ {
152
+ "$prototype": "Array",
153
+ "items": {
154
+ "$ref": "#/state/rows"
155
+ },
156
+ "key": {
157
+ "$ref": "$map/item/id"
158
+ },
159
+ "map": {
160
+ "tagName": "jx-menu-item",
161
+ "$props": {
162
+ "value": {
163
+ "$ref": "$map/item/id"
164
+ },
165
+ "disabled": {
166
+ "$ref": "$map/item/disabled"
167
+ },
168
+ "destructive": {
169
+ "$ref": "$map/item/destructive"
170
+ },
171
+ "requires": {
172
+ "$ref": "$map/item/requires"
173
+ },
174
+ "haspopup": {
175
+ "$ref": "$map/item/haspopup"
176
+ },
177
+ "checked": {
178
+ "$ref": "$map/item/checked"
179
+ }
180
+ },
181
+ "children": [
182
+ {
183
+ "tagName": "jx-icon",
184
+ "attributes": {
185
+ "slot": "icon"
186
+ },
187
+ "$props": {
188
+ "name": "copy"
189
+ }
190
+ },
191
+ {
192
+ "tagName": "span",
193
+ "textContent": "${$map.item.title}"
194
+ },
195
+ {
196
+ "tagName": "kbd",
197
+ "attributes": {
198
+ "slot": "value"
199
+ },
200
+ "hidden": {
201
+ "$ref": "$map/item/noChord"
202
+ },
203
+ "textContent": "${$map.item.chord}"
204
+ },
205
+ {
206
+ "tagName": "span",
207
+ "attributes": {
208
+ "slot": "description"
209
+ },
210
+ "hidden": {
211
+ "$ref": "$map/item/enabled"
212
+ },
213
+ "textContent": "Needs ${$map.item.requires}"
214
+ }
215
+ ]
216
+ }
217
+ }
218
+ ]
219
+ }
220
+ ]
221
+ }