@elliemae/ds-system 3.48.2-rc.0 → 3.49.0-beta.2

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.
@@ -89,180 +89,180 @@ __export(HtmlComponents_exports, {
89
89
  });
90
90
  module.exports = __toCommonJS(HtmlComponents_exports);
91
91
  var React = __toESM(require("react"));
92
- var import_index = require("./index.js");
92
+ var import_styled = require("./styled/styled.js");
93
93
  var import_xStyledWrapper = require("./xStyledWrapper.js");
94
- const Address = (0, import_index.styled)("address")`
94
+ const Address = (0, import_styled.styled)("address")`
95
95
  ${import_xStyledWrapper.xStyledCommonProps}
96
96
  `;
97
- const Article = (0, import_index.styled)("article")`
97
+ const Article = (0, import_styled.styled)("article")`
98
98
  ${import_xStyledWrapper.xStyledCommonProps}
99
99
  `;
100
- const Aside = (0, import_index.styled)("aside")`
100
+ const Aside = (0, import_styled.styled)("aside")`
101
101
  ${import_xStyledWrapper.xStyledCommonProps}
102
102
  `;
103
- const Footer = (0, import_index.styled)("footer")`
103
+ const Footer = (0, import_styled.styled)("footer")`
104
104
  ${import_xStyledWrapper.xStyledCommonProps}
105
105
  `;
106
- const Header = (0, import_index.styled)("header")`
106
+ const Header = (0, import_styled.styled)("header")`
107
107
  ${import_xStyledWrapper.xStyledCommonProps}
108
108
  `;
109
- const H1 = (0, import_index.styled)("h1")`
109
+ const H1 = (0, import_styled.styled)("h1")`
110
110
  ${import_xStyledWrapper.xStyledCommonProps}
111
111
  `;
112
- const H2 = (0, import_index.styled)("h2")`
112
+ const H2 = (0, import_styled.styled)("h2")`
113
113
  ${import_xStyledWrapper.xStyledCommonProps}
114
114
  `;
115
- const H3 = (0, import_index.styled)("h3")`
115
+ const H3 = (0, import_styled.styled)("h3")`
116
116
  ${import_xStyledWrapper.xStyledCommonProps}
117
117
  `;
118
- const H4 = (0, import_index.styled)("h4")`
118
+ const H4 = (0, import_styled.styled)("h4")`
119
119
  ${import_xStyledWrapper.xStyledCommonProps}
120
120
  `;
121
- const H5 = (0, import_index.styled)("h5")`
121
+ const H5 = (0, import_styled.styled)("h5")`
122
122
  ${import_xStyledWrapper.xStyledCommonProps}
123
123
  `;
124
- const H6 = (0, import_index.styled)("h6")`
124
+ const H6 = (0, import_styled.styled)("h6")`
125
125
  ${import_xStyledWrapper.xStyledCommonProps}
126
126
  `;
127
- const Hgroup = (0, import_index.styled)("hgroup")`
127
+ const Hgroup = (0, import_styled.styled)("hgroup")`
128
128
  ${import_xStyledWrapper.xStyledCommonProps}
129
129
  `;
130
- const Main = (0, import_index.styled)("main")`
130
+ const Main = (0, import_styled.styled)("main")`
131
131
  ${import_xStyledWrapper.xStyledCommonProps}
132
132
  `;
133
- const Nav = (0, import_index.styled)("nav")`
133
+ const Nav = (0, import_styled.styled)("nav")`
134
134
  ${import_xStyledWrapper.xStyledCommonProps}
135
135
  `;
136
- const Section = (0, import_index.styled)("section")`
136
+ const Section = (0, import_styled.styled)("section")`
137
137
  ${import_xStyledWrapper.xStyledCommonProps}
138
138
  `;
139
- const Search = (0, import_index.styled)("search")`
139
+ const Search = (0, import_styled.styled)("search")`
140
140
  ${import_xStyledWrapper.xStyledCommonProps}
141
141
  `;
142
- const Blockquote = (0, import_index.styled)("blockquote")`
142
+ const Blockquote = (0, import_styled.styled)("blockquote")`
143
143
  ${import_xStyledWrapper.xStyledCommonProps}
144
144
  `;
145
- const Dd = (0, import_index.styled)("dd")`
145
+ const Dd = (0, import_styled.styled)("dd")`
146
146
  ${import_xStyledWrapper.xStyledCommonProps}
147
147
  `;
148
- const Div = (0, import_index.styled)("div")`
148
+ const Div = (0, import_styled.styled)("div")`
149
149
  ${import_xStyledWrapper.xStyledCommonProps}
150
150
  `;
151
- const Dl = (0, import_index.styled)("dl")`
151
+ const Dl = (0, import_styled.styled)("dl")`
152
152
  ${import_xStyledWrapper.xStyledCommonProps}
153
153
  `;
154
- const Dt = (0, import_index.styled)("dt")`
154
+ const Dt = (0, import_styled.styled)("dt")`
155
155
  ${import_xStyledWrapper.xStyledCommonProps}
156
156
  `;
157
- const Figcaption = (0, import_index.styled)("figcaption")`
157
+ const Figcaption = (0, import_styled.styled)("figcaption")`
158
158
  ${import_xStyledWrapper.xStyledCommonProps}
159
159
  `;
160
- const Figure = (0, import_index.styled)("figure")`
160
+ const Figure = (0, import_styled.styled)("figure")`
161
161
  ${import_xStyledWrapper.xStyledCommonProps}
162
162
  `;
163
- const Hr = (0, import_index.styled)("hr")`
163
+ const Hr = (0, import_styled.styled)("hr")`
164
164
  ${import_xStyledWrapper.xStyledCommonProps}
165
165
  `;
166
- const Li = (0, import_index.styled)("li")`
166
+ const Li = (0, import_styled.styled)("li")`
167
167
  ${import_xStyledWrapper.xStyledCommonProps}
168
168
  `;
169
- const Menu = (0, import_index.styled)("menu")`
169
+ const Menu = (0, import_styled.styled)("menu")`
170
170
  ${import_xStyledWrapper.xStyledCommonProps}
171
171
  `;
172
- const Ol = (0, import_index.styled)("ol")`
172
+ const Ol = (0, import_styled.styled)("ol")`
173
173
  ${import_xStyledWrapper.xStyledCommonProps}
174
174
  `;
175
- const P = (0, import_index.styled)("p")`
175
+ const P = (0, import_styled.styled)("p")`
176
176
  ${import_xStyledWrapper.xStyledCommonProps}
177
177
  `;
178
- const Pre = (0, import_index.styled)("pre")`
178
+ const Pre = (0, import_styled.styled)("pre")`
179
179
  ${import_xStyledWrapper.xStyledCommonProps}
180
180
  `;
181
- const Ul = (0, import_index.styled)("ul")`
181
+ const Ul = (0, import_styled.styled)("ul")`
182
182
  ${import_xStyledWrapper.xStyledCommonProps}
183
183
  `;
184
- const A = (0, import_index.styled)("a")`
184
+ const A = (0, import_styled.styled)("a")`
185
185
  ${import_xStyledWrapper.xStyledCommonProps}
186
186
  `;
187
- const Abbr = (0, import_index.styled)("abbr")`
187
+ const Abbr = (0, import_styled.styled)("abbr")`
188
188
  ${import_xStyledWrapper.xStyledCommonProps}
189
189
  `;
190
- const B = (0, import_index.styled)("b")`
190
+ const B = (0, import_styled.styled)("b")`
191
191
  ${import_xStyledWrapper.xStyledCommonProps}
192
192
  `;
193
- const Bdi = (0, import_index.styled)("bdi")`
193
+ const Bdi = (0, import_styled.styled)("bdi")`
194
194
  ${import_xStyledWrapper.xStyledCommonProps}
195
195
  `;
196
- const Bdo = (0, import_index.styled)("bdo")`
196
+ const Bdo = (0, import_styled.styled)("bdo")`
197
197
  ${import_xStyledWrapper.xStyledCommonProps}
198
198
  `;
199
- const Br = (0, import_index.styled)("br")`
199
+ const Br = (0, import_styled.styled)("br")`
200
200
  ${import_xStyledWrapper.xStyledCommonProps}
201
201
  `;
202
- const Cite = (0, import_index.styled)("cite")`
202
+ const Cite = (0, import_styled.styled)("cite")`
203
203
  ${import_xStyledWrapper.xStyledCommonProps}
204
204
  `;
205
- const Code = (0, import_index.styled)("code")`
205
+ const Code = (0, import_styled.styled)("code")`
206
206
  ${import_xStyledWrapper.xStyledCommonProps}
207
207
  `;
208
- const Data = (0, import_index.styled)("data")`
208
+ const Data = (0, import_styled.styled)("data")`
209
209
  ${import_xStyledWrapper.xStyledCommonProps}
210
210
  `;
211
- const Dfn = (0, import_index.styled)("dfn")`
211
+ const Dfn = (0, import_styled.styled)("dfn")`
212
212
  ${import_xStyledWrapper.xStyledCommonProps}
213
213
  `;
214
- const Em = (0, import_index.styled)("em")`
214
+ const Em = (0, import_styled.styled)("em")`
215
215
  ${import_xStyledWrapper.xStyledCommonProps}
216
216
  `;
217
- const I = (0, import_index.styled)("i")`
217
+ const I = (0, import_styled.styled)("i")`
218
218
  ${import_xStyledWrapper.xStyledCommonProps}
219
219
  `;
220
- const Kbd = (0, import_index.styled)("kbd")`
220
+ const Kbd = (0, import_styled.styled)("kbd")`
221
221
  ${import_xStyledWrapper.xStyledCommonProps}
222
222
  `;
223
- const Mark = (0, import_index.styled)("mark")`
223
+ const Mark = (0, import_styled.styled)("mark")`
224
224
  ${import_xStyledWrapper.xStyledCommonProps}
225
225
  `;
226
- const Q = (0, import_index.styled)("q")`
226
+ const Q = (0, import_styled.styled)("q")`
227
227
  ${import_xStyledWrapper.xStyledCommonProps}
228
228
  `;
229
- const Rp = (0, import_index.styled)("rp")`
229
+ const Rp = (0, import_styled.styled)("rp")`
230
230
  ${import_xStyledWrapper.xStyledCommonProps}
231
231
  `;
232
- const Rt = (0, import_index.styled)("rt")`
232
+ const Rt = (0, import_styled.styled)("rt")`
233
233
  ${import_xStyledWrapper.xStyledCommonProps}
234
234
  `;
235
- const Ruby = (0, import_index.styled)("ruby")`
235
+ const Ruby = (0, import_styled.styled)("ruby")`
236
236
  ${import_xStyledWrapper.xStyledCommonProps}
237
237
  `;
238
- const S = (0, import_index.styled)("s")`
238
+ const S = (0, import_styled.styled)("s")`
239
239
  ${import_xStyledWrapper.xStyledCommonProps}
240
240
  `;
241
- const Samp = (0, import_index.styled)("samp")`
241
+ const Samp = (0, import_styled.styled)("samp")`
242
242
  ${import_xStyledWrapper.xStyledCommonProps}
243
243
  `;
244
- const Small = (0, import_index.styled)("small")`
244
+ const Small = (0, import_styled.styled)("small")`
245
245
  ${import_xStyledWrapper.xStyledCommonProps}
246
246
  `;
247
- const Span = (0, import_index.styled)("span")`
247
+ const Span = (0, import_styled.styled)("span")`
248
248
  ${import_xStyledWrapper.xStyledCommonProps}
249
249
  `;
250
- const Strong = (0, import_index.styled)("strong")`
250
+ const Strong = (0, import_styled.styled)("strong")`
251
251
  ${import_xStyledWrapper.xStyledCommonProps}
252
252
  `;
253
- const Sub = (0, import_index.styled)("sub")`
253
+ const Sub = (0, import_styled.styled)("sub")`
254
254
  ${import_xStyledWrapper.xStyledCommonProps}
255
255
  `;
256
- const Sup = (0, import_index.styled)("sup")`
256
+ const Sup = (0, import_styled.styled)("sup")`
257
257
  ${import_xStyledWrapper.xStyledCommonProps}
258
258
  `;
259
- const Time = (0, import_index.styled)("time")`
259
+ const Time = (0, import_styled.styled)("time")`
260
260
  ${import_xStyledWrapper.xStyledCommonProps}
261
261
  `;
262
- const U = (0, import_index.styled)("u")`
262
+ const U = (0, import_styled.styled)("u")`
263
263
  ${import_xStyledWrapper.xStyledCommonProps}
264
264
  `;
265
- const Wbr = (0, import_index.styled)("wbr")`
265
+ const Wbr = (0, import_styled.styled)("wbr")`
266
266
  ${import_xStyledWrapper.xStyledCommonProps}
267
267
  `;
268
268
  //# sourceMappingURL=HtmlComponents.js.map
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "version": 3,
3
3
  "sources": ["../../src/HtmlComponents.ts", "../../../../../scripts/build/transpile/react-shim.js"],
4
- "sourcesContent": ["import { styled } from './index.js';\nimport type {} from '@xstyled/util';\nimport type {} from '@xstyled/system';\nimport { xStyledCommonProps } from './xStyledWrapper.js';\n\nexport const Address = styled('address')`\n ${xStyledCommonProps}\n`;\nexport const Article = styled('article')`\n ${xStyledCommonProps}\n`;\nexport const Aside = styled('aside')`\n ${xStyledCommonProps}\n`;\nexport const Footer = styled('footer')`\n ${xStyledCommonProps}\n`;\nexport const Header = styled('header')`\n ${xStyledCommonProps}\n`;\nexport const H1 = styled('h1')`\n ${xStyledCommonProps}\n`;\nexport const H2 = styled('h2')`\n ${xStyledCommonProps}\n`;\nexport const H3 = styled('h3')`\n ${xStyledCommonProps}\n`;\nexport const H4 = styled('h4')`\n ${xStyledCommonProps}\n`;\nexport const H5 = styled('h5')`\n ${xStyledCommonProps}\n`;\nexport const H6 = styled('h6')`\n ${xStyledCommonProps}\n`;\nexport const Hgroup = styled('hgroup')`\n ${xStyledCommonProps}\n`;\nexport const Main = styled('main')`\n ${xStyledCommonProps}\n`;\nexport const Nav = styled('nav')`\n ${xStyledCommonProps}\n`;\nexport const Section = styled('section')`\n ${xStyledCommonProps}\n`;\nexport const Search = styled('search')`\n ${xStyledCommonProps}\n`;\nexport const Blockquote = styled('blockquote')`\n ${xStyledCommonProps}\n`;\nexport const Dd = styled('dd')`\n ${xStyledCommonProps}\n`;\nexport const Div = styled('div')`\n ${xStyledCommonProps}\n`;\nexport const Dl = styled('dl')`\n ${xStyledCommonProps}\n`;\nexport const Dt = styled('dt')`\n ${xStyledCommonProps}\n`;\nexport const Figcaption = styled('figcaption')`\n ${xStyledCommonProps}\n`;\nexport const Figure = styled('figure')`\n ${xStyledCommonProps}\n`;\nexport const Hr = styled('hr')`\n ${xStyledCommonProps}\n`;\nexport const Li = styled('li')`\n ${xStyledCommonProps}\n`;\nexport const Menu = styled('menu')`\n ${xStyledCommonProps}\n`;\nexport const Ol = styled('ol')`\n ${xStyledCommonProps}\n`;\nexport const P = styled('p')`\n ${xStyledCommonProps}\n`;\nexport const Pre = styled('pre')`\n ${xStyledCommonProps}\n`;\nexport const Ul = styled('ul')`\n ${xStyledCommonProps}\n`;\nexport const A = styled('a')`\n ${xStyledCommonProps}\n`;\nexport const Abbr = styled('abbr')`\n ${xStyledCommonProps}\n`;\nexport const B = styled('b')`\n ${xStyledCommonProps}\n`;\nexport const Bdi = styled('bdi')`\n ${xStyledCommonProps}\n`;\nexport const Bdo = styled('bdo')`\n ${xStyledCommonProps}\n`;\nexport const Br = styled('br')`\n ${xStyledCommonProps}\n`;\nexport const Cite = styled('cite')`\n ${xStyledCommonProps}\n`;\nexport const Code = styled('code')`\n ${xStyledCommonProps}\n`;\nexport const Data = styled('data')`\n ${xStyledCommonProps}\n`;\nexport const Dfn = styled('dfn')`\n ${xStyledCommonProps}\n`;\nexport const Em = styled('em')`\n ${xStyledCommonProps}\n`;\nexport const I = styled('i')`\n ${xStyledCommonProps}\n`;\nexport const Kbd = styled('kbd')`\n ${xStyledCommonProps}\n`;\nexport const Mark = styled('mark')`\n ${xStyledCommonProps}\n`;\nexport const Q = styled('q')`\n ${xStyledCommonProps}\n`;\nexport const Rp = styled('rp')`\n ${xStyledCommonProps}\n`;\nexport const Rt = styled('rt')`\n ${xStyledCommonProps}\n`;\nexport const Ruby = styled('ruby')`\n ${xStyledCommonProps}\n`;\nexport const S = styled('s')`\n ${xStyledCommonProps}\n`;\nexport const Samp = styled('samp')`\n ${xStyledCommonProps}\n`;\nexport const Small = styled('small')`\n ${xStyledCommonProps}\n`;\nexport const Span = styled('span')`\n ${xStyledCommonProps}\n`;\nexport const Strong = styled('strong')`\n ${xStyledCommonProps}\n`;\nexport const Sub = styled('sub')`\n ${xStyledCommonProps}\n`;\nexport const Sup = styled('sup')`\n ${xStyledCommonProps}\n`;\nexport const Time = styled('time')`\n ${xStyledCommonProps}\n`;\nexport const U = styled('u')`\n ${xStyledCommonProps}\n`;\nexport const Wbr = styled('wbr')`\n ${xStyledCommonProps}\n`;\n", "import * as React from 'react';\nexport { React };\n"],
5
- "mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;ACAA,YAAuB;ADAvB,mBAAuB;AAGvB,4BAAmC;AAE5B,MAAM,cAAU,qBAAO,SAAS;AAAA,IACnC,wCAAkB;AAAA;AAEf,MAAM,cAAU,qBAAO,SAAS;AAAA,IACnC,wCAAkB;AAAA;AAEf,MAAM,YAAQ,qBAAO,OAAO;AAAA,IAC/B,wCAAkB;AAAA;AAEf,MAAM,aAAS,qBAAO,QAAQ;AAAA,IACjC,wCAAkB;AAAA;AAEf,MAAM,aAAS,qBAAO,QAAQ;AAAA,IACjC,wCAAkB;AAAA;AAEf,MAAM,SAAK,qBAAO,IAAI;AAAA,IACzB,wCAAkB;AAAA;AAEf,MAAM,SAAK,qBAAO,IAAI;AAAA,IACzB,wCAAkB;AAAA;AAEf,MAAM,SAAK,qBAAO,IAAI;AAAA,I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AAAA;AAEf,MAAM,YAAQ,qBAAO,OAAO;AAAA,IAC/B,wCAAkB;AAAA;AAEf,MAAM,WAAO,qBAAO,MAAM;AAAA,IAC7B,wCAAkB;AAAA;AAEf,MAAM,aAAS,qBAAO,QAAQ;AAAA,IACjC,wCAAkB;AAAA;AAEf,MAAM,UAAM,qBAAO,KAAK;AAAA,IAC3B,wCAAkB;AAAA;AAEf,MAAM,UAAM,qBAAO,KAAK;AAAA,IAC3B,wCAAkB;AAAA;AAEf,MAAM,WAAO,qBAAO,MAAM;AAAA,IAC7B,wCAAkB;AAAA;AAEf,MAAM,QAAI,qBAAO,GAAG;AAAA,IACvB,wCAAkB;AAAA;AAEf,MAAM,UAAM,qBAAO,KAAK;AAAA,IAC3B,wCAAkB;AAAA;",
4
+ "sourcesContent": ["import type {} from '@xstyled/system';\nimport type {} from '@xstyled/util';\nimport { styled } from './styled/styled.js';\nimport { xStyledCommonProps } from './xStyledWrapper.js';\n\nexport const Address = styled('address')`\n ${xStyledCommonProps}\n`;\nexport const Article = styled('article')`\n ${xStyledCommonProps}\n`;\nexport const Aside = styled('aside')`\n ${xStyledCommonProps}\n`;\nexport const Footer = styled('footer')`\n ${xStyledCommonProps}\n`;\nexport const Header = styled('header')`\n ${xStyledCommonProps}\n`;\nexport const H1 = styled('h1')`\n ${xStyledCommonProps}\n`;\nexport const H2 = styled('h2')`\n ${xStyledCommonProps}\n`;\nexport const H3 = styled('h3')`\n ${xStyledCommonProps}\n`;\nexport const H4 = styled('h4')`\n ${xStyledCommonProps}\n`;\nexport const H5 = styled('h5')`\n ${xStyledCommonProps}\n`;\nexport const H6 = styled('h6')`\n ${xStyledCommonProps}\n`;\nexport const Hgroup = styled('hgroup')`\n ${xStyledCommonProps}\n`;\nexport const Main = styled('main')`\n ${xStyledCommonProps}\n`;\nexport const Nav = styled('nav')`\n ${xStyledCommonProps}\n`;\nexport const Section = styled('section')`\n ${xStyledCommonProps}\n`;\n\nexport const Search = styled('search')`\n ${xStyledCommonProps}\n`;\nexport const Blockquote = styled('blockquote')`\n ${xStyledCommonProps}\n`;\nexport const Dd = styled('dd')`\n ${xStyledCommonProps}\n`;\nexport const Div = styled('div')`\n ${xStyledCommonProps}\n`;\nexport const Dl = styled('dl')`\n ${xStyledCommonProps}\n`;\nexport const Dt = styled('dt')`\n ${xStyledCommonProps}\n`;\nexport const Figcaption = styled('figcaption')`\n ${xStyledCommonProps}\n`;\nexport const Figure = styled('figure')`\n ${xStyledCommonProps}\n`;\nexport const Hr = styled('hr')`\n ${xStyledCommonProps}\n`;\nexport const Li = styled('li')`\n ${xStyledCommonProps}\n`;\nexport const Menu = styled('menu')`\n ${xStyledCommonProps}\n`;\nexport const Ol = styled('ol')`\n ${xStyledCommonProps}\n`;\nexport const P = styled('p')`\n ${xStyledCommonProps}\n`;\nexport const Pre = styled('pre')`\n ${xStyledCommonProps}\n`;\nexport const Ul = styled('ul')`\n ${xStyledCommonProps}\n`;\nexport const A = styled('a')`\n ${xStyledCommonProps}\n`;\nexport const Abbr = styled('abbr')`\n ${xStyledCommonProps}\n`;\nexport const B = styled('b')`\n ${xStyledCommonProps}\n`;\nexport const Bdi = styled('bdi')`\n ${xStyledCommonProps}\n`;\nexport const Bdo = styled('bdo')`\n ${xStyledCommonProps}\n`;\nexport const Br = styled('br')`\n ${xStyledCommonProps}\n`;\nexport const Cite = styled('cite')`\n ${xStyledCommonProps}\n`;\nexport const Code = styled('code')`\n ${xStyledCommonProps}\n`;\nexport const Data = styled('data')`\n ${xStyledCommonProps}\n`;\nexport const Dfn = styled('dfn')`\n ${xStyledCommonProps}\n`;\nexport const Em = styled('em')`\n ${xStyledCommonProps}\n`;\nexport const I = styled('i')`\n ${xStyledCommonProps}\n`;\nexport const Kbd = styled('kbd')`\n ${xStyledCommonProps}\n`;\nexport const Mark = styled('mark')`\n ${xStyledCommonProps}\n`;\nexport const Q = styled('q')`\n ${xStyledCommonProps}\n`;\nexport const Rp = styled('rp')`\n ${xStyledCommonProps}\n`;\nexport const Rt = styled('rt')`\n ${xStyledCommonProps}\n`;\nexport const Ruby = styled('ruby')`\n ${xStyledCommonProps}\n`;\nexport const S = styled('s')`\n ${xStyledCommonProps}\n`;\nexport const Samp = styled('samp')`\n ${xStyledCommonProps}\n`;\nexport const Small = styled('small')`\n ${xStyledCommonProps}\n`;\nexport const Span = styled('span')`\n ${xStyledCommonProps}\n`;\nexport const Strong = styled('strong')`\n ${xStyledCommonProps}\n`;\nexport const Sub = styled('sub')`\n ${xStyledCommonProps}\n`;\nexport const Sup = styled('sup')`\n ${xStyledCommonProps}\n`;\nexport const Time = styled('time')`\n ${xStyledCommonProps}\n`;\nexport const U = styled('u')`\n ${xStyledCommonProps}\n`;\nexport const Wbr = styled('wbr')`\n ${xStyledCommonProps}\n`;\n", "import * as React from 'react';\nexport { React };\n"],
5
+ "mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;ACAA,YAAuB;ADEvB,oBAAuB;AACvB,4BAAmC;AAE5B,MAAM,cAAU,sBAAO,SAAS;AAAA,IACnC,wCAAkB;AAAA;AAEf,MAAM,cAAU,sBAAO,SAAS;AAAA,IACnC,wCAAkB;AAAA;AAEf,MAAM,YAAQ,sBAAO,OAAO;AAAA,IAC/B,wCAAkB;AAAA;AAEf,MAAM,aAAS,sBAAO,QAAQ;AAAA,IACjC,wCAAkB;AAAA;AAEf,MAAM,aAAS,sBAAO,QAAQ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CAAkB;AAAA;AAEf,MAAM,WAAO,sBAAO,MAAM;AAAA,IAC7B,wCAAkB;AAAA;AAEf,MAAM,QAAI,sBAAO,GAAG;AAAA,IACvB,wCAAkB;AAAA;AAEf,MAAM,WAAO,sBAAO,MAAM;AAAA,IAC7B,wCAAkB;AAAA;AAEf,MAAM,YAAQ,sBAAO,OAAO;AAAA,IAC/B,wCAAkB;AAAA;AAEf,MAAM,WAAO,sBAAO,MAAM;AAAA,IAC7B,wCAAkB;AAAA;AAEf,MAAM,aAAS,sBAAO,QAAQ;AAAA,IACjC,wCAAkB;AAAA;AAEf,MAAM,UAAM,sBAAO,KAAK;AAAA,IAC3B,wCAAkB;AAAA;AAEf,MAAM,UAAM,sBAAO,KAAK;AAAA,IAC3B,wCAAkB;AAAA;AAEf,MAAM,WAAO,sBAAO,MAAM;AAAA,IAC7B,wCAAkB;AAAA;AAEf,MAAM,QAAI,sBAAO,GAAG;AAAA,IACvB,wCAAkB;AAAA;AAEf,MAAM,UAAM,sBAAO,KAAK;AAAA,IAC3B,wCAAkB;AAAA;",
6
6
  "names": []
7
7
  }
@@ -33,18 +33,18 @@ __export(styledFunction_exports, {
33
33
  module.exports = __toCommonJS(styledFunction_exports);
34
34
  var React = __toESM(require("react"));
35
35
  var import_jsx_runtime = require("react/jsx-runtime");
36
+ var import_react = require("react");
36
37
  var import_checkNamingConvention = require("./checkNamingConvention.js");
37
- var import_system = require("./system.js");
38
- var import_transformers = require("./transformers/index.js");
39
38
  var import_coerceWithDefaultTheme = require("./coerceWithDefaultTheme.js");
40
39
  var import_expressions = require("./expressions/index.js");
41
40
  var import_fixStyleArg = require("./fixStyleArg.js");
42
- var import_generated_attributes = require("./generated-attributes/index.js");
43
41
  var import_generateAttributes = require("./generated-attributes/generateAttributes.js");
42
+ var import_generated_attributes = require("./generated-attributes/index.js");
43
+ var import_callbackMerger = require("./generated-attributes/utils/callbackMerger.js");
44
44
  var import_refMerger = require("./generated-attributes/utils/refMerger.js");
45
45
  var import_helpers = require("./helpers.js");
46
- var import_react = require("react");
47
- var import_callbackMerger = require("./generated-attributes/utils/callbackMerger.js");
46
+ var import_system = require("./system.js");
47
+ var import_transformers = require("./transformers/index.js");
48
48
  const defaultOptions = {
49
49
  name: null,
50
50
  slot: null
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "version": 3,
3
3
  "sources": ["../../../src/styled/styledFunction.tsx", "../../../../../../scripts/build/transpile/react-shim.js"],
4
- "sourcesContent": ["/* eslint-disable no-unused-vars */\n/* eslint-disable @typescript-eslint/ban-types */\n/* eslint-disable @typescript-eslint/no-explicit-any */\nimport type { AnyStyledComponent, ThemedStyledFunction } from 'styled-components';\nimport { checkNamingConvention } from './checkNamingConvention.js';\nimport { styled as baseStyled } from './system.js';\nimport { dsStyledComponentTransform, magicCssTransform } from './transformers/index.js';\nimport type {\n AnyStyledRef,\n Options,\n OwnerInterface,\n InnerRefInterface,\n Theme,\n ThemedStyledFunctionBase,\n} from './types.js';\nimport { coerceWithDefaultTheme } from './coerceWithDefaultTheme.js';\nimport { genStyleOverridesExpression, genVariantOverridesExpression } from './expressions/index.js';\nimport { fixStyleArg } from './fixStyleArg.js';\nimport { generateAutoCalculated } from './generated-attributes/index.js';\nimport { getPartProps } from './generated-attributes/generateAttributes.js';\nimport { mergeRefs } from './generated-attributes/utils/refMerger.js';\nimport { displayNameToKebabCase, displayNameToPropCase } from './helpers.js';\nimport React, { useMemo } from 'react';\nimport { callbackMerger } from './generated-attributes/utils/callbackMerger.js';\n\nconst defaultOptions: Options = {\n name: null,\n slot: null,\n};\n\nexport const styledFunction = <C extends AnyStyledComponent | keyof JSX.IntrinsicElements | React.ComponentType<any>>(\n tag: C,\n options: Options = defaultOptions,\n) => {\n const { name: componentName, slot: componentSlot } = options;\n\n checkNamingConvention(componentName, componentSlot);\n\n // Here we use the `as` because when C is keyof JSX.IntrinsicElements we get `never` for the attributes generic\n // We want to account for string | number | symbol that's why we transform it to `keyof any`\n const baseStyledResolver = baseStyled(tag) as unknown as ThemedStyledFunction<C, Theme, {}, keyof any>;\n\n // Due to the recursive natura of this function, we can't type it properly\n // Since we can apply .attrs or .withConfig, we are not sure on the type of the returned function\n // @ts-expect-error explained above\n const dsStyledResolver: ThemedStyledFunctionBase<C, Theme> = (styleArg, ...expressions) => {\n /**\n * Here we apply a transformation to the expressions only.\n * Since this resolver is returning a HOC of a styled-component, the syntax support for\n * selecting the className of another styled-component is not available anymore.\n * That's why we assign it a `dsStyledComponnentId`, we will replace the component's call for\n * the corresponding id\n */\n const expressionsWithDsStyledComponentId = dsStyledComponentTransform(expressions);\n\n /**\n * Here we apply a CSS transformation to support MAGIC styled components\n * This makes it possible to use the following syntax:\n * color: neutral-100;\n * background-color: success-900;\n */\n const [styleArgWithMagic, expressionsWithMagic] = magicCssTransform(styleArg, expressionsWithDsStyledComponentId);\n\n /**\n * We coerce all the already written expressions with the default theme\n * This prevents styled components to break when a theme is not provided\n * either with the HOC or the ThemeProvider\n */\n const expressionsWithThemeCoerced = coerceWithDefaultTheme(expressionsWithMagic);\n\n if (componentName && componentSlot) {\n // Here we add the style overrides expression\n expressionsWithThemeCoerced.push(genStyleOverridesExpression(componentName, componentSlot));\n }\n\n if (componentName && componentSlot === 'root') {\n // Here we add the variant overrides from the user (only for the root slot\n expressionsWithThemeCoerced.push(genVariantOverridesExpression(componentName));\n }\n\n /**\n * Here we will fix the format of the style argument\n * We possible added some new expressions into the mix,\n * so we need to properly adjust the style arg\n */\n const numOfExpressionsAdded = expressionsWithThemeCoerced.length - expressionsWithMagic.length;\n\n const fixedStyleArg = fixStyleArg(styleArgWithMagic, numOfExpressionsAdded);\n\n // We will add autocalculated attributes to the styled component\n const [displayName, attributes] = generateAutoCalculated(options);\n\n // For each attribute function, we will call `attrs` func with it\n // This will add the attributes to the styled component\n const baseStyledResolverWithAttributes = attributes.reduce<typeof baseStyledResolver>(\n (curStyledResolver, attributeFunc) => curStyledResolver.attrs(attributeFunc),\n baseStyledResolver,\n );\n\n const Component = baseStyledResolverWithAttributes(fixedStyleArg, ...expressionsWithThemeCoerced);\n\n const ComponentWithRefsMerged = (props: OwnerInterface & InnerRefInterface<C> & { 'data-testid'?: string }) => {\n // we may or not have data-testid at this point, so we need to calculate it\n const dataTestId = props['data-testid'] ?? (displayName !== null ? displayNameToKebabCase(displayName) : '');\n // we also need to calculate dataDimsumSlot at this point\n const dataDimsumSlot = displayName !== null ? displayNameToPropCase(displayName) : '';\n // then we get the part props for this slot, and we cast it to use refs\n const partProps = getPartProps({\n ...props,\n 'data-testid': dataTestId,\n 'data-dimsum-slot': dataDimsumSlot,\n }) as {\n innerRef?: AnyStyledRef<HTMLElement>;\n };\n\n // then we merge the callbacks from the props with the ones from the part\n // this object also has all global props from the parts\n const resultingObjectWithCallbackMerged = callbackMerger(props, partProps);\n\n const mergedRef = useMemo(\n () => mergeRefs(props.innerRef, partProps.innerRef),\n [props.innerRef, partProps.innerRef],\n );\n\n // We don't want to pass the owner props to the component down the line\n const { getOwnerProps, getOwnerPropsArguments, ...restProps } = props;\n // TODO:\n // deploy the following code and see if we break something in a dedicated effort ASAP\n // let ref = undefined;\n // eslint-disable-next-line @typescript-eslint/ban-ts-comment\n // @ts-ignore : as of thue 16 may 2024, Component.target.$$typeof is undefined for non-native react components\n // eslint-disable-next-line @typescript-eslint/no-unsafe-member-access\n // if (typeof Component?.target === 'string') {\n // ref = mergedRef;\n // }\n\n const propsWithRefMerged = {\n ...restProps,\n ...resultingObjectWithCallbackMerged,\n // ref: ref,\n ref: mergedRef,\n innerRef: mergedRef,\n } as React.ComponentProps<C>;\n\n // TODO: check if we need to pass the ref to the component\n // Check $$typeof to see if it's a react-forward-ref\n // Check dsStyledComponentId to see if it's a styled component\n // Check what to do with span, div, etc.\n // Other cases should not receive ref...?\n\n return <Component {...propsWithRefMerged} />;\n };\n\n if (displayName !== null) {\n Component.displayName = displayName;\n }\n\n // eslint-disable-next-line @typescript-eslint/ban-ts-comment\n // @ts-ignore We use dsStyledComponent to access the original's component id\n ComponentWithRefsMerged.dsStyledComponentId = Component.styledComponentId as string;\n ComponentWithRefsMerged.toString = Component.toString;\n\n return ComponentWithRefsMerged;\n };\n\n // Here we use arrow functions to preserve the `this` context\n const styledAttributes = {\n attrs: ((...args) => {\n baseStyledResolver.attrs(...args);\n return dsStyledResolver;\n }) as (typeof baseStyledResolver)['attrs'],\n withConfig: ((...args) => {\n baseStyledResolver.withConfig(...args);\n return dsStyledResolver;\n }) as (typeof baseStyledResolver)['withConfig'],\n };\n\n return Object.assign(dsStyledResolver, styledAttributes);\n};\n", "import * as React from 'react';\nexport { React };\n"],
5
- "mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;ACAA,YAAuB;ADsJV;AAlJb,mCAAsC;AACtC,oBAAqC;AACrC,0BAA8D;AAS9D,oCAAuC;AACvC,yBAA2E;AAC3E,yBAA4B;AAC5B,kCAAuC;AACvC,gCAA6B;AAC7B,uBAA0B;AAC1B,qBAA8D;AAC9D,mBAA+B;AAC/B,4BAA+B;AAE/B,MAAM,iBAA0B;AAAA,EAC9B,MAAM;AAAA,EACN,MAAM;AACR;AAEO,MAAM,iBAAiB,CAC5B,KACA,UAAmB,mBAChB;AACH,QAAM,EAAE,MAAM,eAAe,MAAM,cAAc,IAAI;AAErD,0DAAsB,eAAe,aAAa;AAIlD,QAAM,yBAAqB,cAAAA,QAAW,GAAG;AAKzC,QAAM,mBAAuD,CAAC,aAAa,gBAAgB;AAQzF,UAAM,yCAAqC,gDAA2B,WAAW;AAQjF,UAAM,CAAC,mBAAmB,oBAAoB,QAAI,uCAAkB,UAAU,kCAAkC;AAOhH,UAAM,kCAA8B,sDAAuB,oBAAoB;AAE/E,QAAI,iBAAiB,eAAe;AAElC,kCAA4B,SAAK,gDAA4B,eAAe,aAAa,CAAC;AAAA,IAC5F;AAEA,QAAI,iBAAiB,kBAAkB,QAAQ;AAE7C,kCAA4B,SAAK,kDAA8B,aAAa,CAAC;AAAA,IAC/E;AAOA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,IAAI;AACrC,aAAO;AAAA,IACT;AAAA,EACF;AAEA,SAAO,OAAO,OAAO,kBAAkB,gBAAgB;AACzD;",
4
+ "sourcesContent": ["/* eslint-disable no-unused-vars */\n/* eslint-disable @typescript-eslint/ban-types */\n/* eslint-disable @typescript-eslint/no-explicit-any */\nimport React, { useMemo } from 'react';\nimport type { AnyStyledComponent, ThemedStyledFunction } from 'styled-components';\nimport { checkNamingConvention } from './checkNamingConvention.js';\nimport { coerceWithDefaultTheme } from './coerceWithDefaultTheme.js';\nimport { genStyleOverridesExpression, genVariantOverridesExpression } from './expressions/index.js';\nimport { fixStyleArg } from './fixStyleArg.js';\nimport { getPartProps } from './generated-attributes/generateAttributes.js';\nimport { generateAutoCalculated } from './generated-attributes/index.js';\nimport { callbackMerger } from './generated-attributes/utils/callbackMerger.js';\nimport { mergeRefs } from './generated-attributes/utils/refMerger.js';\nimport { displayNameToKebabCase, displayNameToPropCase } from './helpers.js';\nimport { styled as baseStyled } from './system.js';\nimport { dsStyledComponentTransform, magicCssTransform } from './transformers/index.js';\nimport type {\n AnyStyledRef,\n InnerRefInterface,\n Options,\n OwnerInterface,\n Theme,\n ThemedStyledFunctionBase,\n} from './types.js';\n\nconst defaultOptions: Options = {\n name: null,\n slot: null,\n};\n\nexport const styledFunction = <\n C extends AnyStyledComponent | keyof React.JSX.IntrinsicElements | React.ComponentType<any>,\n>(\n tag: C,\n options: Options = defaultOptions,\n) => {\n const { name: componentName, slot: componentSlot } = options;\n\n checkNamingConvention(componentName, componentSlot);\n\n // Here we use the `as` because when C is keyof JSX.IntrinsicElements we get `never` for the attributes generic\n // We want to account for string | number | symbol that's why we transform it to `keyof any`\n const baseStyledResolver = baseStyled(tag) as unknown as ThemedStyledFunction<C, Theme, {}, keyof any>;\n\n // Due to the recursive natura of this function, we can't type it properly\n // Since we can apply .attrs or .withConfig, we are not sure on the type of the returned function\n // @ts-expect-error explained above\n const dsStyledResolver: ThemedStyledFunctionBase<C, Theme> = (styleArg, ...expressions) => {\n /**\n * Here we apply a transformation to the expressions only.\n * Since this resolver is returning a HOC of a styled-component, the syntax support for\n * selecting the className of another styled-component is not available anymore.\n * That's why we assign it a `dsStyledComponnentId`, we will replace the component's call for\n * the corresponding id\n */\n const expressionsWithDsStyledComponentId = dsStyledComponentTransform(expressions);\n\n /**\n * Here we apply a CSS transformation to support MAGIC styled components\n * This makes it possible to use the following syntax:\n * color: neutral-100;\n * background-color: success-900;\n */\n const [styleArgWithMagic, expressionsWithMagic] = magicCssTransform(styleArg, expressionsWithDsStyledComponentId);\n\n /**\n * We coerce all the already written expressions with the default theme\n * This prevents styled components to break when a theme is not provided\n * either with the HOC or the ThemeProvider\n */\n const expressionsWithThemeCoerced = coerceWithDefaultTheme(expressionsWithMagic);\n\n if (componentName && componentSlot) {\n // Here we add the style overrides expression\n expressionsWithThemeCoerced.push(genStyleOverridesExpression(componentName, componentSlot));\n }\n\n if (componentName && componentSlot === 'root') {\n // Here we add the variant overrides from the user (only for the root slot\n expressionsWithThemeCoerced.push(genVariantOverridesExpression(componentName));\n }\n\n /**\n * Here we will fix the format of the style argument\n * We possible added some new expressions into the mix,\n * so we need to properly adjust the style arg\n */\n const numOfExpressionsAdded = expressionsWithThemeCoerced.length - expressionsWithMagic.length;\n\n const fixedStyleArg = fixStyleArg(styleArgWithMagic, numOfExpressionsAdded);\n\n // We will add autocalculated attributes to the styled component\n const [displayName, attributes] = generateAutoCalculated(options);\n\n // For each attribute function, we will call `attrs` func with it\n // This will add the attributes to the styled component\n const baseStyledResolverWithAttributes = attributes.reduce<typeof baseStyledResolver>(\n (curStyledResolver, attributeFunc) => curStyledResolver.attrs(attributeFunc),\n baseStyledResolver,\n );\n\n const Component = baseStyledResolverWithAttributes(fixedStyleArg, ...expressionsWithThemeCoerced);\n\n const ComponentWithRefsMerged = (props: OwnerInterface & InnerRefInterface<C> & { 'data-testid'?: string }) => {\n // we may or not have data-testid at this point, so we need to calculate it\n const dataTestId = props['data-testid'] ?? (displayName !== null ? displayNameToKebabCase(displayName) : '');\n // we also need to calculate dataDimsumSlot at this point\n const dataDimsumSlot = displayName !== null ? displayNameToPropCase(displayName) : '';\n // then we get the part props for this slot, and we cast it to use refs\n const partProps = getPartProps({\n ...props,\n 'data-testid': dataTestId,\n 'data-dimsum-slot': dataDimsumSlot,\n }) as {\n innerRef?: AnyStyledRef<HTMLElement>;\n };\n\n // then we merge the callbacks from the props with the ones from the part\n // this object also has all global props from the parts\n const resultingObjectWithCallbackMerged = callbackMerger(props, partProps);\n\n const mergedRef = useMemo(\n () => mergeRefs(props.innerRef, partProps.innerRef),\n [props.innerRef, partProps.innerRef],\n );\n\n // We don't want to pass the owner props to the component down the line\n const { getOwnerProps, getOwnerPropsArguments, ...restProps } = props;\n // TODO:\n // deploy the following code and see if we break something in a dedicated effort ASAP\n // let ref = undefined;\n // eslint-disable-next-line @typescript-eslint/ban-ts-comment\n // @ts-ignore : as of thue 16 may 2024, Component.target.$$typeof is undefined for non-native react components\n // eslint-disable-next-line @typescript-eslint/no-unsafe-member-access\n // if (typeof Component?.target === 'string') {\n // ref = mergedRef;\n // }\n\n const propsWithRefMerged = {\n ...restProps,\n ...resultingObjectWithCallbackMerged,\n // ref: ref,\n ref: mergedRef,\n innerRef: mergedRef,\n } as React.ComponentProps<C>;\n\n // TODO: check if we need to pass the ref to the component\n // Check $$typeof to see if it's a react-forward-ref\n // Check dsStyledComponentId to see if it's a styled component\n // Check what to do with span, div, etc.\n // Other cases should not receive ref...?\n\n return <Component {...propsWithRefMerged} />;\n };\n\n if (displayName !== null) {\n Component.displayName = displayName;\n }\n\n // eslint-disable-next-line @typescript-eslint/ban-ts-comment\n // @ts-ignore We use dsStyledComponent to access the original's component id\n ComponentWithRefsMerged.dsStyledComponentId = Component.styledComponentId as string;\n // eslint-disable-next-line @typescript-eslint/unbound-method\n ComponentWithRefsMerged.toString = Component.toString;\n\n return ComponentWithRefsMerged;\n };\n\n // Here we use arrow functions to preserve the `this` context\n const styledAttributes = {\n attrs: ((...args) => {\n baseStyledResolver.attrs(...args);\n return dsStyledResolver;\n }) as (typeof baseStyledResolver)['attrs'],\n withConfig: ((...args) => {\n baseStyledResolver.withConfig(...args);\n return dsStyledResolver;\n }) as (typeof baseStyledResolver)['withConfig'],\n };\n\n return Object.assign(dsStyledResolver, styledAttributes);\n};\n", "import * as React from 'react';\nexport { React };\n"],
5
+ "mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;ACAA,YAAuB;ADwJV;AArJb,mBAA+B;AAE/B,mCAAsC;AACtC,oCAAuC;AACvC,yBAA2E;AAC3E,yBAA4B;AAC5B,gCAA6B;AAC7B,kCAAuC;AACvC,4BAA+B;AAC/B,uBAA0B;AAC1B,qBAA8D;AAC9D,oBAAqC;AACrC,0BAA8D;AAU9D,MAAM,iBAA0B;AAAA,EAC9B,MAAM;AAAA,EACN,MAAM;AACR;AAEO,MAAM,iBAAiB,CAG5B,KACA,UAAmB,mBAChB;AACH,QAAM,EAAE,MAAM,eAAe,MAAM,cAAc,IAAI;AAErD,0DAAsB,eAAe,aAAa;AAIlD,QAAM,yBAAqB,cAAAA,QAAW,GAAG;AAKzC,QAAM,mBAAuD,CAAC,aAAa,gBAAgB;AAQzF,UAAM,yCAAqC,gDAA2B,WAAW;AAQjF,UAAM,CAAC,mBAAmB,oBAAoB,QAAI,uCAAkB,UAAU,kCAAkC;AAOhH,UAAM,kCAA8B,sDAAuB,oBAAoB;AAE/E,QAAI,iBAAiB,eAAe;AAElC,kCAA4B,SAAK,gDAA4B,eAAe,aAAa,CAAC;AAAA,IAC5F;AAEA,QAAI,iBAAiB,kBAAkB,QAAQ;AAE7C,kCAA4B,SAAK,kDAA8B,aAAa,CAAC;AAAA,IAC/E;AAOA,UAAM,wBAAwB,4BAA4B,SAAS,qBAAqB;AAExF,UAAM,oBAAgB,gCAAY,mBAAmB,qBAAqB;AAG1E,UAAM,CAAC,aAAa,UAAU,QAAI,oDAAuB,OAAO;AAIhE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
1
  {
2
2
  "version": 3,
3
3
  "sources": ["../../../src/styled/styledObject.ts", "../../../../../../scripts/build/transpile/react-shim.js"],
4
- "sourcesContent": ["import { styledFunction } from './styledFunction.js';\nimport { styled as baseStyled } from './system.js';\n\ntype PreStyledObject = {\n [TTag in keyof JSX.IntrinsicElements]: unknown;\n};\n\nexport type StyledObject = {\n [TTag in keyof JSX.IntrinsicElements]: ReturnType<typeof styledFunction<TTag>>;\n};\n\nconst keyofJsxIntrinsicElements = Object.keys(baseStyled) as (keyof JSX.IntrinsicElements)[];\n\nexport const styledObject = keyofJsxIntrinsicElements.reduce((obj, key) => {\n obj[key] = styledFunction(key);\n return obj;\n}, {} as PreStyledObject) as StyledObject;\n", "import * as React from 'react';\nexport { React };\n"],
5
- "mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;ACAA,YAAuB;ADAvB,4BAA+B;AAC/B,oBAAqC;AAUrC,MAAM,4BAA4B,OAAO,KAAK,cAAAA,MAAU;AAEjD,MAAM,eAAe,0BAA0B,OAAO,CAAC,KAAK,QAAQ;AACzE,MAAI,GAAG,QAAI,sCAAe,GAAG;AAC7B,SAAO;AACT,GAAG,CAAC,CAAoB;",
4
+ "sourcesContent": ["import type React from 'react';\nimport { styledFunction } from './styledFunction.js';\nimport { styled as baseStyled } from './system.js';\n\ntype PreStyledObject = {\n [TTag in keyof React.JSX.IntrinsicElements]: unknown;\n};\n\nexport type StyledObject = {\n [TTag in keyof React.JSX.IntrinsicElements]: ReturnType<typeof styledFunction<TTag>>;\n};\n\nconst keyofJsxIntrinsicElements = Object.keys(baseStyled) as (keyof React.JSX.IntrinsicElements)[];\n\nexport const styledObject = keyofJsxIntrinsicElements.reduce((obj, key) => {\n obj[key] = styledFunction(key);\n return obj;\n}, {} as PreStyledObject) as StyledObject;\n", "import * as React from 'react';\nexport { React };\n"],
5
+ "mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;ACAA,YAAuB;ADCvB,4BAA+B;AAC/B,oBAAqC;AAUrC,MAAM,4BAA4B,OAAO,KAAK,cAAAA,MAAU;AAEjD,MAAM,eAAe,0BAA0B,OAAO,CAAC,KAAK,QAAQ;AACzE,MAAI,GAAG,QAAI,sCAAe,GAAG;AAC7B,SAAO;AACT,GAAG,CAAC,CAAoB;",
6
6
  "names": ["baseStyled"]
7
7
  }
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "version": 3,
3
3
  "sources": ["../../../src/styled/types.ts", "../../../../../../scripts/build/transpile/react-shim.js"],
4
- "sourcesContent": ["/* eslint-disable @typescript-eslint/ban-types */\n/* eslint-disable @typescript-eslint/no-explicit-any */\nimport type {\n AnyStyledComponent,\n CSSObject,\n Interpolation,\n InterpolationFunction,\n StyledComponent,\n StyledComponentInnerComponent,\n StyledComponentPropsWithRef,\n ThemedStyledProps,\n} from 'styled-components';\nimport type { Theme as PuiTheme } from '@elliemae/pui-theme';\nimport type { ElementType, Ref } from 'react';\nimport type React from 'react';\n\nexport interface Options {\n name: string | null;\n slot: string | null;\n}\n\nexport interface Theme extends PuiTheme {\n layoutMode?: 'l' | 'm' | 's' | 'xs';\n components?: {\n [componentName: string]: {\n styleOverrides?: CSSObject;\n variants?: { props: Record<string, { toString: () => string }>; style: CSSObject }[];\n };\n };\n}\n\nexport type AnyStyledRef<T extends HTMLElement> =\n | React.MutableRefObject<T | null>\n | ((_ref: T | null) => void)\n | false\n | null;\n\nexport type StyleArg<T = any> = TemplateStringsArray | CSSObject | InterpolationFunction<T>;\nexport type Expression<T = any> = Interpolation<T>;\nexport type Expressions<T = any> = Array<Expression<T>>;\nexport type PropsWithTheme<T = Record<string, unknown>> = T & { theme: Theme };\n\ntype ComponentInnerRef<T extends ElementType> = T extends new (props: infer P) => React.Component<any, any>\n ? Ref<InstanceType<T>> | undefined\n : React.PropsWithRef<React.ComponentProps<T>>['ref'];\n\nexport type StyledComponentInnerRef<C extends keyof JSX.IntrinsicElements | React.ComponentType<any>> =\n C extends AnyStyledComponent ? ComponentInnerRef<StyledComponentInnerComponent<C>> : ComponentInnerRef<C>;\n\nexport interface ThemedStyledFunctionBase<\n C extends keyof JSX.IntrinsicElements | React.ComponentType<any>,\n T extends object,\n O extends object = {},\n A extends keyof any = never,\n> {\n <U extends object>(\n first: StyleArg<\n ThemedStyledProps<StyledComponentPropsWithRef<C> & O & U & OwnerInterface & InnerRefInterface<C>, T>\n >,\n ...rest: Expressions<\n ThemedStyledProps<StyledComponentPropsWithRef<C> & O & U & OwnerInterface & InnerRefInterface<C>, T>\n >\n ): StyledComponent<C, T, O & U & OwnerInterface & InnerRefInterface<C>, A>;\n}\n\nexport type AttrsFunc<T extends object = Record<string, unknown>> = (\n props: StyledComponentPropsWithRef<StyledComponentInnerComponent<React.ComponentType<T>>>,\n) => Partial<StyledComponentPropsWithRef<StyledComponentInnerComponent<any>>>;\n\nexport type InternalAttrsFunc<T extends object = Record<string, unknown>> = (\n props: StyledComponentPropsWithRef<\n StyledComponentInnerComponent<React.ComponentType<T & { ref?: AnyStyledRef<HTMLElement> }>>\n >,\n meta: {\n options: Options;\n displayName: string | null;\n },\n) => Partial<StyledComponentPropsWithRef<StyledComponentInnerComponent<any>>>;\n\nexport interface InnerRefInterface<C extends keyof JSX.IntrinsicElements | React.ComponentType<any>> {\n innerRef?: StyledComponentInnerRef<C>;\n ref?: never;\n}\n\nexport interface OwnerInterface {\n getOwnerProps?: () => object;\n getOwnerPropsArguments?: () => object;\n}\n\nexport type PartProps = Record<string, unknown> | ((args: object) => Record<string, unknown>) | null | undefined;\n", "import * as React from 'react';\nexport { React };\n"],
4
+ "sourcesContent": ["/* eslint-disable @typescript-eslint/ban-types */\n/* eslint-disable @typescript-eslint/no-explicit-any */\nimport type {\n AnyStyledComponent,\n CSSObject,\n Interpolation,\n InterpolationFunction,\n StyledComponent,\n StyledComponentInnerComponent,\n StyledComponentPropsWithRef,\n ThemedStyledProps,\n} from 'styled-components';\nimport type { Theme as PuiTheme } from '@elliemae/pui-theme';\nimport type { ElementType, Ref } from 'react';\nimport type React from 'react';\n\nexport interface Options {\n name: string | null;\n slot: string | null;\n}\n\nexport interface Theme extends PuiTheme {\n layoutMode?: 'l' | 'm' | 's' | 'xs';\n components?: {\n [componentName: string]: {\n styleOverrides?: CSSObject;\n variants?: { props: Record<string, { toString: () => string }>; style: CSSObject }[];\n };\n };\n}\n\nexport type AnyStyledRef<T extends HTMLElement> =\n | React.MutableRefObject<T | null>\n | ((_ref: T | null) => void)\n | false\n | null;\n\nexport type StyleArg<T = any> = TemplateStringsArray | CSSObject | InterpolationFunction<T>;\nexport type Expression<T = any> = Interpolation<T>;\nexport type Expressions<T = any> = Array<Expression<T>>;\nexport type PropsWithTheme<T = Record<string, unknown>> = T & { theme: Theme };\n\ntype ComponentInnerRef<T extends ElementType> = T extends new (props: infer P) => React.Component<any, any>\n ? Ref<InstanceType<T>> | undefined\n : React.PropsWithRef<React.ComponentProps<T>>['ref'];\n\nexport type StyledComponentInnerRef<C extends keyof React.JSX.IntrinsicElements | React.ComponentType<any>> =\n C extends AnyStyledComponent ? ComponentInnerRef<StyledComponentInnerComponent<C>> : ComponentInnerRef<C>;\n\nexport interface ThemedStyledFunctionBase<\n C extends keyof React.JSX.IntrinsicElements | React.ComponentType<any>,\n T extends object,\n O extends object = {},\n A extends keyof any = never,\n> {\n <U extends object>(\n first: StyleArg<\n ThemedStyledProps<StyledComponentPropsWithRef<C> & O & U & OwnerInterface & InnerRefInterface<C>, T>\n >,\n ...rest: Expressions<\n ThemedStyledProps<StyledComponentPropsWithRef<C> & O & U & OwnerInterface & InnerRefInterface<C>, T>\n >\n ): StyledComponent<C, T, O & U & OwnerInterface & InnerRefInterface<C>, A>;\n}\n\nexport type AttrsFunc<T extends object = Record<string, unknown>> = (\n props: StyledComponentPropsWithRef<StyledComponentInnerComponent<React.ComponentType<T>>>,\n) => Partial<StyledComponentPropsWithRef<StyledComponentInnerComponent<any>>>;\n\nexport type InternalAttrsFunc<T extends object = Record<string, unknown>> = (\n props: StyledComponentPropsWithRef<\n StyledComponentInnerComponent<React.ComponentType<T & { ref?: AnyStyledRef<HTMLElement> }>>\n >,\n meta: {\n options: Options;\n displayName: string | null;\n },\n) => Partial<StyledComponentPropsWithRef<StyledComponentInnerComponent<any>>>;\n\nexport interface InnerRefInterface<C extends keyof React.JSX.IntrinsicElements | React.ComponentType<any>> {\n innerRef?: StyledComponentInnerRef<C>;\n ref?: never;\n}\n\nexport interface OwnerInterface {\n getOwnerProps?: () => object;\n getOwnerPropsArguments?: () => object;\n}\n\nexport type PartProps = Record<string, unknown> | ((args: object) => Record<string, unknown>) | null | undefined;\n", "import * as React from 'react';\nexport { React };\n"],
5
5
  "mappings": ";;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;ACAA,YAAuB;",
6
6
  "names": []
7
7
  }
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "version": 3,
3
3
  "sources": ["../../src/themeProviderHOC.tsx", "../../../../../scripts/build/transpile/react-shim.js"],
4
- "sourcesContent": ["import React from 'react';\nimport { ThemeProvider } from '@xstyled/styled-components';\nimport { theme } from './theme.js';\n\nexport const themeProviderHOC = <T extends JSX.IntrinsicAttributes>(Component: React.ComponentType<T>) => {\n const WrappedComponent: React.ComponentType<T> = (props) => (\n <ThemeProvider\n theme={{\n ...theme,\n layoutMode: 'l',\n }}\n >\n <Component {...props} />\n </ThemeProvider>\n );\n return WrappedComponent;\n};\n", "import * as React from 'react';\nexport { React };\n"],
5
- "mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;ACAA,YAAuB;ADYjB;AAXN,+BAA8B;AAC9B,mBAAsB;AAEf,MAAM,mBAAmB,CAAoC,cAAsC;AACxG,QAAM,mBAA2C,CAAC,UAChD;AAAA,IAAC;AAAA;AAAA,MACC,OAAO;AAAA,QACL,GAAG;AAAA,QACH,YAAY;AAAA,MACd;AAAA,MAEA,sDAAC,aAAW,GAAG,OAAO;AAAA;AAAA,EACxB;AAEF,SAAO;AACT;",
4
+ "sourcesContent": ["import React from 'react';\nimport { ThemeProvider } from '@xstyled/styled-components';\nimport { theme } from './theme.js';\n\nexport const themeProviderHOC = <T extends React.JSX.IntrinsicAttributes>(Component: React.ComponentType<T>) => {\n const WrappedComponent: React.ComponentType<T> = (props) => (\n <ThemeProvider\n theme={{\n ...theme,\n layoutMode: 'l',\n }}\n >\n <Component {...props} />\n </ThemeProvider>\n );\n return WrappedComponent;\n};\n", "import * as React from 'react';\nexport { React };\n"],
5
+ "mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;ACAA,YAAuB;ADYjB;AAXN,+BAA8B;AAC9B,mBAAsB;AAEf,MAAM,mBAAmB,CAA0C,cAAsC;AAC9G,QAAM,mBAA2C,CAAC,UAChD;AAAA,IAAC;AAAA;AAAA,MACC,OAAO;AAAA,QACL,GAAG;AAAA,QACH,YAAY;AAAA,MACd;AAAA,MAEA,sDAAC,aAAW,GAAG,OAAO;AAAA;AAAA,EACxB;AAEF,SAAO;AACT;",
6
6
  "names": []
7
7
  }
@@ -34,29 +34,34 @@ __export(xStyledWrapper_exports, {
34
34
  });
35
35
  module.exports = __toCommonJS(xStyledWrapper_exports);
36
36
  var React = __toESM(require("react"));
37
- var import_index = require("./index.js");
38
37
  var import_system = require("@xstyled/system");
39
- const XStyledWrapper = (0, import_index.styled)("div")`
40
- ${import_index.typography}
41
- ${import_index.layout}
42
- ${import_index.space}
43
- ${import_index.sizing}
44
- ${import_index.background}
45
- ${import_index.borders}
46
- ${import_index.boxShadows}
47
- ${import_index.flexboxes}
48
- ${import_index.color}
38
+ var import_styled = require("./styled/styled.js");
39
+ var import_background = require("./styled/system-utilities/background.js");
40
+ var import_border = require("./styled/system-utilities/border.js");
41
+ var import_color = require("./styled/system-utilities/color.js");
42
+ var import_sizing = require("./styled/system-utilities/sizing.js");
43
+ var import_space = require("./styled/system-utilities/space.js");
44
+ const XStyledWrapper = (0, import_styled.styled)("div")`
45
+ ${import_system.typography}
46
+ ${import_system.layout}
47
+ ${import_space.space}
48
+ ${import_sizing.sizing}
49
+ ${import_background.background}
50
+ ${import_border.borders}
51
+ ${import_system.boxShadow}
52
+ ${import_system.flexboxes}
53
+ ${import_color.color}
49
54
  `;
50
55
  const xStyledCommonProps = (0, import_system.compose)(
51
- import_index.typography,
52
- import_index.background,
53
- import_index.borders,
54
- import_index.sizing,
55
- import_index.space,
56
- import_index.boxShadows,
57
- import_index.flexboxes,
58
- import_index.layout,
59
- import_index.color
56
+ import_system.typography,
57
+ import_background.background,
58
+ import_border.borders,
59
+ import_sizing.sizing,
60
+ import_space.space,
61
+ import_system.boxShadow,
62
+ import_system.flexboxes,
63
+ import_system.layout,
64
+ import_color.color
60
65
  );
61
66
  var xStyledWrapper_default = XStyledWrapper;
62
67
  //# sourceMappingURL=xStyledWrapper.js.map
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "version": 3,
3
3
  "sources": ["../../src/xStyledWrapper.tsx", "../../../../../scripts/build/transpile/react-shim.js"],
4
- "sourcesContent": ["import {\n styled,\n typography,\n background,\n borders,\n sizing,\n space,\n boxShadows,\n flexboxes,\n layout,\n color,\n} from './index.js';\nimport type {} from '@xstyled/util';\nimport type {} from '@xstyled/system';\nimport { compose } from '@xstyled/system';\n\nexport const XStyledWrapper = styled('div')`\n ${typography}\n ${layout}\n ${space}\n ${sizing}\n ${background}\n ${borders}\n ${boxShadows}\n ${flexboxes}\n ${color}\n`;\n\nexport const xStyledCommonProps = compose(\n typography,\n background,\n borders,\n sizing,\n space,\n boxShadows,\n flexboxes,\n layout,\n color,\n);\n\nexport default XStyledWrapper;\n", "import * as React from 'react';\nexport { React };\n"],
5
- "mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;ACAA,YAAuB;ADAvB,mBAWO;AAGP,oBAAwB;AAEjB,MAAM,qBAAiB,qBAAO,KAAK;AAAA,IACtC,uBAAU;AAAA,IACV,mBAAM;AAAA,IACN,kBAAK;AAAA,IACL,mBAAM;AAAA,IACN,uBAAU;AAAA,IACV,oBAAO;AAAA,IACP,uBAAU;AAAA,IACV,sBAAS;AAAA,IACT,kBAAK;AAAA;AAGF,MAAM,yBAAqB;AAAA,EAChC;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AACF;AAEA,IAAO,yBAAQ;",
6
- "names": []
4
+ "sourcesContent": ["import type {} from '@xstyled/system';\nimport { boxShadow as boxShadows, compose, flexboxes, layout, typography } from '@xstyled/system';\nimport type {} from '@xstyled/util';\nimport { styled } from './styled/styled.js';\nimport { background } from './styled/system-utilities/background.js';\nimport { borders } from './styled/system-utilities/border.js';\nimport { color } from './styled/system-utilities/color.js';\nimport { sizing } from './styled/system-utilities/sizing.js';\nimport { space } from './styled/system-utilities/space.js';\n\nexport const XStyledWrapper = styled('div')`\n ${typography}\n ${layout}\n ${space}\n ${sizing}\n ${background}\n ${borders}\n ${boxShadows}\n ${flexboxes}\n ${color}\n`;\n\nexport const xStyledCommonProps = compose(\n typography,\n background,\n borders,\n sizing,\n space,\n boxShadows,\n flexboxes,\n layout,\n color,\n);\n\nexport default XStyledWrapper;\n", "import * as React from 'react';\nexport { React };\n"],
5
+ "mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;ACAA,YAAuB;ADCvB,oBAAgF;AAEhF,oBAAuB;AACvB,wBAA2B;AAC3B,oBAAwB;AACxB,mBAAsB;AACtB,oBAAuB;AACvB,mBAAsB;AAEf,MAAM,qBAAiB,sBAAO,KAAK;AAAA,IACtC,wBAAU;AAAA,IACV,oBAAM;AAAA,IACN,kBAAK;AAAA,IACL,oBAAM;AAAA,IACN,4BAAU;AAAA,IACV,qBAAO;AAAA,IACP,cAAAA,SAAU;AAAA,IACV,uBAAS;AAAA,IACT,kBAAK;AAAA;AAGF,MAAM,yBAAqB;AAAA,EAChC;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA,cAAAA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AACF;AAEA,IAAO,yBAAQ;",
6
+ "names": ["boxShadows"]
7
7
  }
@@ -1,5 +1,5 @@
1
1
  import * as React from "react";
2
- import { styled } from "./index.js";
2
+ import { styled } from "./styled/styled.js";
3
3
  import { xStyledCommonProps } from "./xStyledWrapper.js";
4
4
  const Address = styled("address")`
5
5
  ${xStyledCommonProps}
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "version": 3,
3
3
  "sources": ["../../../../../scripts/build/transpile/react-shim.js", "../../src/HtmlComponents.ts"],
4
- "sourcesContent": ["import * as React from 'react';\nexport { React };\n", "import { styled } from './index.js';\nimport type {} from '@xstyled/util';\nimport type {} from '@xstyled/system';\nimport { xStyledCommonProps } from './xStyledWrapper.js';\n\nexport const Address = styled('address')`\n ${xStyledCommonProps}\n`;\nexport const Article = styled('article')`\n ${xStyledCommonProps}\n`;\nexport const Aside = styled('aside')`\n ${xStyledCommonProps}\n`;\nexport const Footer = styled('footer')`\n ${xStyledCommonProps}\n`;\nexport const Header = styled('header')`\n ${xStyledCommonProps}\n`;\nexport const H1 = styled('h1')`\n ${xStyledCommonProps}\n`;\nexport const H2 = styled('h2')`\n ${xStyledCommonProps}\n`;\nexport const H3 = styled('h3')`\n ${xStyledCommonProps}\n`;\nexport const H4 = styled('h4')`\n ${xStyledCommonProps}\n`;\nexport const H5 = styled('h5')`\n ${xStyledCommonProps}\n`;\nexport const H6 = styled('h6')`\n ${xStyledCommonProps}\n`;\nexport const Hgroup = styled('hgroup')`\n ${xStyledCommonProps}\n`;\nexport const Main = styled('main')`\n ${xStyledCommonProps}\n`;\nexport const Nav = styled('nav')`\n ${xStyledCommonProps}\n`;\nexport const Section = styled('section')`\n ${xStyledCommonProps}\n`;\nexport const Search = styled('search')`\n ${xStyledCommonProps}\n`;\nexport const Blockquote = styled('blockquote')`\n ${xStyledCommonProps}\n`;\nexport const Dd = styled('dd')`\n ${xStyledCommonProps}\n`;\nexport const Div = styled('div')`\n ${xStyledCommonProps}\n`;\nexport const Dl = styled('dl')`\n ${xStyledCommonProps}\n`;\nexport const Dt = styled('dt')`\n ${xStyledCommonProps}\n`;\nexport const Figcaption = styled('figcaption')`\n ${xStyledCommonProps}\n`;\nexport const Figure = styled('figure')`\n ${xStyledCommonProps}\n`;\nexport const Hr = styled('hr')`\n ${xStyledCommonProps}\n`;\nexport const Li = styled('li')`\n ${xStyledCommonProps}\n`;\nexport const Menu = styled('menu')`\n ${xStyledCommonProps}\n`;\nexport const Ol = styled('ol')`\n ${xStyledCommonProps}\n`;\nexport const P = styled('p')`\n ${xStyledCommonProps}\n`;\nexport const Pre = styled('pre')`\n ${xStyledCommonProps}\n`;\nexport const Ul = styled('ul')`\n ${xStyledCommonProps}\n`;\nexport const A = styled('a')`\n ${xStyledCommonProps}\n`;\nexport const Abbr = styled('abbr')`\n ${xStyledCommonProps}\n`;\nexport const B = styled('b')`\n ${xStyledCommonProps}\n`;\nexport const Bdi = styled('bdi')`\n ${xStyledCommonProps}\n`;\nexport const Bdo = styled('bdo')`\n ${xStyledCommonProps}\n`;\nexport const Br = styled('br')`\n ${xStyledCommonProps}\n`;\nexport const Cite = styled('cite')`\n ${xStyledCommonProps}\n`;\nexport const Code = styled('code')`\n ${xStyledCommonProps}\n`;\nexport const Data = styled('data')`\n ${xStyledCommonProps}\n`;\nexport const Dfn = styled('dfn')`\n ${xStyledCommonProps}\n`;\nexport const Em = styled('em')`\n ${xStyledCommonProps}\n`;\nexport const I = styled('i')`\n ${xStyledCommonProps}\n`;\nexport const Kbd = styled('kbd')`\n ${xStyledCommonProps}\n`;\nexport const Mark = styled('mark')`\n ${xStyledCommonProps}\n`;\nexport const Q = styled('q')`\n ${xStyledCommonProps}\n`;\nexport const Rp = styled('rp')`\n ${xStyledCommonProps}\n`;\nexport const Rt = styled('rt')`\n ${xStyledCommonProps}\n`;\nexport const Ruby = styled('ruby')`\n ${xStyledCommonProps}\n`;\nexport const S = styled('s')`\n ${xStyledCommonProps}\n`;\nexport const Samp = styled('samp')`\n ${xStyledCommonProps}\n`;\nexport const Small = styled('small')`\n ${xStyledCommonProps}\n`;\nexport const Span = styled('span')`\n ${xStyledCommonProps}\n`;\nexport const Strong = styled('strong')`\n ${xStyledCommonProps}\n`;\nexport const Sub = styled('sub')`\n ${xStyledCommonProps}\n`;\nexport const Sup = styled('sup')`\n ${xStyledCommonProps}\n`;\nexport const Time = styled('time')`\n ${xStyledCommonProps}\n`;\nexport const U = styled('u')`\n ${xStyledCommonProps}\n`;\nexport const Wbr = styled('wbr')`\n ${xStyledCommonProps}\n`;\n"],
5
- "mappings": "AAAA,YAAY,WAAW;ACAvB,SAAS,cAAc;AAGvB,SAAS,0BAA0B;AAE5B,MAAM,UAAU,OAAO,SAAS;AAAA,IACnC,kBAAkB;AAAA;AAEf,MAAM,UAAU,OAAO,SAAS;AAAA,IACnC,kBAAkB;AAAA;AAEf,MAAM,QAAQ,OAAO,OAAO;AAAA,IAC/B,kBAAkB;AAAA;AAEf,MAAM,SAAS,OAAO,QAAQ;AAAA,IACjC,kBAAkB;AAAA;AAEf,MAAM,SAAS,OAAO,QAAQ;AAAA,IACjC,kBAAkB;AAAA;AAEf,MAAM,KAAK,OAAO,IAAI;AAAA,IACzB,kBAAkB;AAAA;AAEf,MAAM,KAAK,OAAO,IAAI;AAAA,IACzB,kBAAkB;AAAA;AAEf,MAAM,KAAK,OAAO,IAAI;AAAA,IACzB,kBAAkB;AAAA;AAEf,MAAM,KAAK,OAAO,IAAI;AAAA,IACzB,kBAAkB;AAAA;AAEf,MAAM,KAAK,OAAO,IAAI;AAAA,IACzB,kBAAkB;AAAA;AAEf,MAAM,KAAK,OAAO,IAAI;AAAA,IACzB,kBAAkB;AAAA;AAEf,MAAM,SAAS,OAAO,QAAQ;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,IAC3B,kBAAkB;AAAA;AAEf,MAAM,OAAO,OAAO,MAAM;AAAA,IAC7B,kBAAkB;AAAA;AAEf,MAAM,IAAI,OAAO,GAAG;AAAA,IACvB,kBAAkB;AAAA;AAEf,MAAM,MAAM,OAAO,KAAK;AAAA,IAC3B,kBAAkB;AAAA;",
4
+ "sourcesContent": ["import * as React from 'react';\nexport { React };\n", "import type {} from '@xstyled/system';\nimport type {} from '@xstyled/util';\nimport { styled } from './styled/styled.js';\nimport { xStyledCommonProps } from './xStyledWrapper.js';\n\nexport const Address = styled('address')`\n ${xStyledCommonProps}\n`;\nexport const Article = styled('article')`\n ${xStyledCommonProps}\n`;\nexport const Aside = styled('aside')`\n ${xStyledCommonProps}\n`;\nexport const Footer = styled('footer')`\n ${xStyledCommonProps}\n`;\nexport const Header = styled('header')`\n ${xStyledCommonProps}\n`;\nexport const H1 = styled('h1')`\n ${xStyledCommonProps}\n`;\nexport const H2 = styled('h2')`\n ${xStyledCommonProps}\n`;\nexport const H3 = styled('h3')`\n ${xStyledCommonProps}\n`;\nexport const H4 = styled('h4')`\n ${xStyledCommonProps}\n`;\nexport const H5 = styled('h5')`\n ${xStyledCommonProps}\n`;\nexport const H6 = styled('h6')`\n ${xStyledCommonProps}\n`;\nexport const Hgroup = styled('hgroup')`\n ${xStyledCommonProps}\n`;\nexport const Main = styled('main')`\n ${xStyledCommonProps}\n`;\nexport const Nav = styled('nav')`\n ${xStyledCommonProps}\n`;\nexport const Section = styled('section')`\n ${xStyledCommonProps}\n`;\n\nexport const Search = styled('search')`\n ${xStyledCommonProps}\n`;\nexport const Blockquote = styled('blockquote')`\n ${xStyledCommonProps}\n`;\nexport const Dd = styled('dd')`\n ${xStyledCommonProps}\n`;\nexport const Div = styled('div')`\n ${xStyledCommonProps}\n`;\nexport const Dl = styled('dl')`\n ${xStyledCommonProps}\n`;\nexport const Dt = styled('dt')`\n ${xStyledCommonProps}\n`;\nexport const Figcaption = styled('figcaption')`\n ${xStyledCommonProps}\n`;\nexport const Figure = styled('figure')`\n ${xStyledCommonProps}\n`;\nexport const Hr = styled('hr')`\n ${xStyledCommonProps}\n`;\nexport const Li = styled('li')`\n ${xStyledCommonProps}\n`;\nexport const Menu = styled('menu')`\n ${xStyledCommonProps}\n`;\nexport const Ol = styled('ol')`\n ${xStyledCommonProps}\n`;\nexport const P = styled('p')`\n ${xStyledCommonProps}\n`;\nexport const Pre = styled('pre')`\n ${xStyledCommonProps}\n`;\nexport const Ul = styled('ul')`\n ${xStyledCommonProps}\n`;\nexport const A = styled('a')`\n ${xStyledCommonProps}\n`;\nexport const Abbr = styled('abbr')`\n ${xStyledCommonProps}\n`;\nexport const B = styled('b')`\n ${xStyledCommonProps}\n`;\nexport const Bdi = styled('bdi')`\n ${xStyledCommonProps}\n`;\nexport const Bdo = styled('bdo')`\n ${xStyledCommonProps}\n`;\nexport const Br = styled('br')`\n ${xStyledCommonProps}\n`;\nexport const Cite = styled('cite')`\n ${xStyledCommonProps}\n`;\nexport const Code = styled('code')`\n ${xStyledCommonProps}\n`;\nexport const Data = styled('data')`\n ${xStyledCommonProps}\n`;\nexport const Dfn = styled('dfn')`\n ${xStyledCommonProps}\n`;\nexport const Em = styled('em')`\n ${xStyledCommonProps}\n`;\nexport const I = styled('i')`\n ${xStyledCommonProps}\n`;\nexport const Kbd = styled('kbd')`\n ${xStyledCommonProps}\n`;\nexport const Mark = styled('mark')`\n ${xStyledCommonProps}\n`;\nexport const Q = styled('q')`\n ${xStyledCommonProps}\n`;\nexport const Rp = styled('rp')`\n ${xStyledCommonProps}\n`;\nexport const Rt = styled('rt')`\n ${xStyledCommonProps}\n`;\nexport const Ruby = styled('ruby')`\n ${xStyledCommonProps}\n`;\nexport const S = styled('s')`\n ${xStyledCommonProps}\n`;\nexport const Samp = styled('samp')`\n ${xStyledCommonProps}\n`;\nexport const Small = styled('small')`\n ${xStyledCommonProps}\n`;\nexport const Span = styled('span')`\n ${xStyledCommonProps}\n`;\nexport const Strong = styled('strong')`\n ${xStyledCommonProps}\n`;\nexport const Sub = styled('sub')`\n ${xStyledCommonProps}\n`;\nexport const Sup = styled('sup')`\n ${xStyledCommonProps}\n`;\nexport const Time = styled('time')`\n ${xStyledCommonProps}\n`;\nexport const U = styled('u')`\n ${xStyledCommonProps}\n`;\nexport const Wbr = styled('wbr')`\n ${xStyledCommonProps}\n`;\n"],
5
+ "mappings": "AAAA,YAAY,WAAW;ACEvB,SAAS,cAAc;AACvB,SAAS,0BAA0B;AAE5B,MAAM,UAAU,OAAO,SAAS;AAAA,IACnC,kBAAkB;AAAA;AAEf,MAAM,UAAU,OAAO,SAAS;AAAA,IACnC,kBAAkB;AAAA;AAEf,MAAM,QAAQ,OAAO,OAAO;AAAA,IAC/B,kBAAkB;AAAA;AAEf,MAAM,SAAS,OAAO,QAAQ;AAAA,IACjC,kBAAkB;AAAA;AAEf,MAAM,SAAS,OAAO,QAAQ;AAAA,IACjC,kBAAkB;AAAA;AAEf,MAAM,KAAK,OAAO,IAAI;AAAA,IACzB,kBAAkB;AAAA;AAEf,MAAM,KAAK,OAAO,IAAI;AAAA,IACzB,kBAAkB;AAAA;AAEf,MAAM,KAAK,OAAO,IAAI;AAAA,IACzB,kBAAkB;AAAA;AAEf,MAAM,KAAK,OAAO,IAAI;AAAA,IACzB,kBAAkB;AAAA;AAEf,MAAM,KAAK,OAAO,IAAI;AAAA,IACzB,kBAAkB;AAAA;AAEf,MAAM,KAAK,OAAO,IAAI;AAAA,IACzB,kBAAkB;AAAA;AAEf,MAAM,SAAS,OAAO,QAAQ;AAAA,IACjC,kBAAkB;AAAA;AAEf,MAAM,OAAO,OAAO,MAAM;AAAA,IAC7B,kBAAkB;AAAA;AAEf,MAAM,MAAM,OAAO,KAAK;AAAA,IAC3B,kBAAkB;AAAA;AAEf,MAAM,UAAU,OAAO,SAAS;AAAA,IACnC,kBAAkB;AAAA;AAGf,MAAM,SAAS,OAAO,QAAQ;AAAA,IACjC,kBAAkB;AAAA;AAEf,MAAM,aAAa,OAAO,Y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
3
+ import { useMemo } from "react";
3
4
  import { checkNamingConvention } from "./checkNamingConvention.js";
4
- import { styled as baseStyled } from "./system.js";
5
- import { dsStyledComponentTransform, magicCssTransform } from "./transformers/index.js";
6
5
  import { coerceWithDefaultTheme } from "./coerceWithDefaultTheme.js";
7
6
  import { genStyleOverridesExpression, genVariantOverridesExpression } from "./expressions/index.js";
8
7
  import { fixStyleArg } from "./fixStyleArg.js";
9
- import { generateAutoCalculated } from "./generated-attributes/index.js";
10
8
  import { getPartProps } from "./generated-attributes/generateAttributes.js";
9
+ import { generateAutoCalculated } from "./generated-attributes/index.js";
10
+ import { callbackMerger } from "./generated-attributes/utils/callbackMerger.js";
11
11
  import { mergeRefs } from "./generated-attributes/utils/refMerger.js";
12
12
  import { displayNameToKebabCase, displayNameToPropCase } from "./helpers.js";
13
- import { useMemo } from "react";
14
- import { callbackMerger } from "./generated-attributes/utils/callbackMerger.js";
13
+ import { styled as baseStyled } from "./system.js";
14
+ import { dsStyledComponentTransform, magicCssTransform } from "./transformers/index.js";
15
15
  const defaultOptions = {
16
16
  name: null,
17
17
  slot: null
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "version": 3,
3
3
  "sources": ["../../../../../../scripts/build/transpile/react-shim.js", "../../../src/styled/styledFunction.tsx"],
4
- "sourcesContent": ["import * as React from 'react';\nexport { React };\n", "/* eslint-disable no-unused-vars */\n/* eslint-disable @typescript-eslint/ban-types */\n/* eslint-disable @typescript-eslint/no-explicit-any */\nimport type { AnyStyledComponent, ThemedStyledFunction } from 'styled-components';\nimport { checkNamingConvention } from './checkNamingConvention.js';\nimport { styled as baseStyled } from './system.js';\nimport { dsStyledComponentTransform, magicCssTransform } from './transformers/index.js';\nimport type {\n AnyStyledRef,\n Options,\n OwnerInterface,\n InnerRefInterface,\n Theme,\n ThemedStyledFunctionBase,\n} from './types.js';\nimport { coerceWithDefaultTheme } from './coerceWithDefaultTheme.js';\nimport { genStyleOverridesExpression, genVariantOverridesExpression } from './expressions/index.js';\nimport { fixStyleArg } from './fixStyleArg.js';\nimport { generateAutoCalculated } from './generated-attributes/index.js';\nimport { getPartProps } from './generated-attributes/generateAttributes.js';\nimport { mergeRefs } from './generated-attributes/utils/refMerger.js';\nimport { displayNameToKebabCase, displayNameToPropCase } from './helpers.js';\nimport React, { useMemo } from 'react';\nimport { callbackMerger } from './generated-attributes/utils/callbackMerger.js';\n\nconst defaultOptions: Options = {\n name: null,\n slot: null,\n};\n\nexport const styledFunction = <C extends AnyStyledComponent | keyof JSX.IntrinsicElements | React.ComponentType<any>>(\n tag: C,\n options: Options = defaultOptions,\n) => {\n const { name: componentName, slot: componentSlot } = options;\n\n checkNamingConvention(componentName, componentSlot);\n\n // Here we use the `as` because when C is keyof JSX.IntrinsicElements we get `never` for the attributes generic\n // We want to account for string | number | symbol that's why we transform it to `keyof any`\n const baseStyledResolver = baseStyled(tag) as unknown as ThemedStyledFunction<C, Theme, {}, keyof any>;\n\n // Due to the recursive natura of this function, we can't type it properly\n // Since we can apply .attrs or .withConfig, we are not sure on the type of the returned function\n // @ts-expect-error explained above\n const dsStyledResolver: ThemedStyledFunctionBase<C, Theme> = (styleArg, ...expressions) => {\n /**\n * Here we apply a transformation to the expressions only.\n * Since this resolver is returning a HOC of a styled-component, the syntax support for\n * selecting the className of another styled-component is not available anymore.\n * That's why we assign it a `dsStyledComponnentId`, we will replace the component's call for\n * the corresponding id\n */\n const expressionsWithDsStyledComponentId = dsStyledComponentTransform(expressions);\n\n /**\n * Here we apply a CSS transformation to support MAGIC styled components\n * This makes it possible to use the following syntax:\n * color: neutral-100;\n * background-color: success-900;\n */\n const [styleArgWithMagic, expressionsWithMagic] = magicCssTransform(styleArg, expressionsWithDsStyledComponentId);\n\n /**\n * We coerce all the already written expressions with the default theme\n * This prevents styled components to break when a theme is not provided\n * either with the HOC or the ThemeProvider\n */\n const expressionsWithThemeCoerced = coerceWithDefaultTheme(expressionsWithMagic);\n\n if (componentName && componentSlot) {\n // Here we add the style overrides expression\n expressionsWithThemeCoerced.push(genStyleOverridesExpression(componentName, componentSlot));\n }\n\n if (componentName && componentSlot === 'root') {\n // Here we add the variant overrides from the user (only for the root slot\n expressionsWithThemeCoerced.push(genVariantOverridesExpression(componentName));\n }\n\n /**\n * Here we will fix the format of the style argument\n * We possible added some new expressions into the mix,\n * so we need to properly adjust the style arg\n */\n const numOfExpressionsAdded = expressionsWithThemeCoerced.length - expressionsWithMagic.length;\n\n const fixedStyleArg = fixStyleArg(styleArgWithMagic, numOfExpressionsAdded);\n\n // We will add autocalculated attributes to the styled component\n const [displayName, attributes] = generateAutoCalculated(options);\n\n // For each attribute function, we will call `attrs` func with it\n // This will add the attributes to the styled component\n const baseStyledResolverWithAttributes = attributes.reduce<typeof baseStyledResolver>(\n (curStyledResolver, attributeFunc) => curStyledResolver.attrs(attributeFunc),\n baseStyledResolver,\n );\n\n const Component = baseStyledResolverWithAttributes(fixedStyleArg, ...expressionsWithThemeCoerced);\n\n const ComponentWithRefsMerged = (props: OwnerInterface & InnerRefInterface<C> & { 'data-testid'?: string }) => {\n // we may or not have data-testid at this point, so we need to calculate it\n const dataTestId = props['data-testid'] ?? (displayName !== null ? displayNameToKebabCase(displayName) : '');\n // we also need to calculate dataDimsumSlot at this point\n const dataDimsumSlot = displayName !== null ? displayNameToPropCase(displayName) : '';\n // then we get the part props for this slot, and we cast it to use refs\n const partProps = getPartProps({\n ...props,\n 'data-testid': dataTestId,\n 'data-dimsum-slot': dataDimsumSlot,\n }) as {\n innerRef?: AnyStyledRef<HTMLElement>;\n };\n\n // then we merge the callbacks from the props with the ones from the part\n // this object also has all global props from the parts\n const resultingObjectWithCallbackMerged = callbackMerger(props, partProps);\n\n const mergedRef = useMemo(\n () => mergeRefs(props.innerRef, partProps.innerRef),\n [props.innerRef, partProps.innerRef],\n );\n\n // We don't want to pass the owner props to the component down the line\n const { getOwnerProps, getOwnerPropsArguments, ...restProps } = props;\n // TODO:\n // deploy the following code and see if we break something in a dedicated effort ASAP\n // let ref = undefined;\n // eslint-disable-next-line @typescript-eslint/ban-ts-comment\n // @ts-ignore : as of thue 16 may 2024, Component.target.$$typeof is undefined for non-native react components\n // eslint-disable-next-line @typescript-eslint/no-unsafe-member-access\n // if (typeof Component?.target === 'string') {\n // ref = mergedRef;\n // }\n\n const propsWithRefMerged = {\n ...restProps,\n ...resultingObjectWithCallbackMerged,\n // ref: ref,\n ref: mergedRef,\n innerRef: mergedRef,\n } as React.ComponentProps<C>;\n\n // TODO: check if we need to pass the ref to the component\n // Check $$typeof to see if it's a react-forward-ref\n // Check dsStyledComponentId to see if it's a styled component\n // Check what to do with span, div, etc.\n // Other cases should not receive ref...?\n\n return <Component {...propsWithRefMerged} />;\n };\n\n if (displayName !== null) {\n Component.displayName = displayName;\n }\n\n // eslint-disable-next-line @typescript-eslint/ban-ts-comment\n // @ts-ignore We use dsStyledComponent to access the original's component id\n ComponentWithRefsMerged.dsStyledComponentId = Component.styledComponentId as string;\n ComponentWithRefsMerged.toString = Component.toString;\n\n return ComponentWithRefsMerged;\n };\n\n // Here we use arrow functions to preserve the `this` context\n const styledAttributes = {\n attrs: ((...args) => {\n baseStyledResolver.attrs(...args);\n return dsStyledResolver;\n }) as (typeof baseStyledResolver)['attrs'],\n withConfig: ((...args) => {\n baseStyledResolver.withConfig(...args);\n return dsStyledResolver;\n }) as (typeof baseStyledResolver)['withConfig'],\n };\n\n return Object.assign(dsStyledResolver, styledAttributes);\n};\n"],
5
- "mappings": "AAAA,YAAY,WAAW;ACsJV;AAlJb,SAAS,6BAA6B;AACtC,SAAS,UAAU,kBAAkB;AACrC,SAAS,4BAA4B,yBAAyB;AAS9D,SAAS,8BAA8B;AACvC,SAAS,6BAA6B,qCAAqC;AAC3E,SAAS,mBAAmB;AAC5B,SAAS,8BAA8B;AACvC,SAAS,oBAAoB;AAC7B,SAAS,iBAAiB;AAC1B,SAAS,wBAAwB,6BAA6B;AAC9D,SAAgB,eAAe;AAC/B,SAAS,sBAAsB;AAE/B,MAAM,iBAA0B;AAAA,E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M,UAAU,UAAU,QAAQ;AAAA,MACrC;AAGA,YAAM,EAAE,eAAe,wBAAwB,GAAG,UAAU,IAAI;AAWhE,YAAM,qBAAqB;AAAA,QACzB,GAAG;AAAA,QACH,GAAG;AAAA;AAAA,QAEH,KAAK;AAAA,QACL,UAAU;AAAA,MACZ;AAQA,aAAO,oBAAC,aAAW,GAAG,oBAAoB;AAAA,IAC5C;AAEA,QAAI,gBAAgB,MAAM;AACxB,gBAAU,cAAc;AAAA,IAC1B;AAIA,4BAAwB,sBAAsB,UAAU;AACxD,4BAAwB,WAAW,UAAU;AAE7C,WAAO;AAAA,EACT;AAGA,QAAM,mBAAmB;AAAA,IACvB,OAAQ,IAAI,SAAS;AACnB,yBAAmB,MAAM,GAAG,IAAI;AAChC,aAAO;AAAA,IACT;AAAA,IACA,YAAa,IAAI,SAAS;AACxB,yBAAmB,WAAW,GAAG,IAAI;AACrC,aAAO;AAAA,IACT;AAAA,EACF;AAEA,SAAO,OAAO,OAAO,kBAAkB,gBAAgB;AACzD;",
4
+ "sourcesContent": ["import * as React from 'react';\nexport { React };\n", "/* eslint-disable no-unused-vars */\n/* eslint-disable @typescript-eslint/ban-types */\n/* eslint-disable @typescript-eslint/no-explicit-any */\nimport React, { useMemo } from 'react';\nimport type { AnyStyledComponent, ThemedStyledFunction } from 'styled-components';\nimport { checkNamingConvention } from './checkNamingConvention.js';\nimport { coerceWithDefaultTheme } from './coerceWithDefaultTheme.js';\nimport { genStyleOverridesExpression, genVariantOverridesExpression } from './expressions/index.js';\nimport { fixStyleArg } from './fixStyleArg.js';\nimport { getPartProps } from './generated-attributes/generateAttributes.js';\nimport { generateAutoCalculated } from './generated-attributes/index.js';\nimport { callbackMerger } from './generated-attributes/utils/callbackMerger.js';\nimport { mergeRefs } from './generated-attributes/utils/refMerger.js';\nimport { displayNameToKebabCase, displayNameToPropCase } from './helpers.js';\nimport { styled as baseStyled } from './system.js';\nimport { dsStyledComponentTransform, magicCssTransform } from './transformers/index.js';\nimport type {\n AnyStyledRef,\n InnerRefInterface,\n Options,\n OwnerInterface,\n Theme,\n ThemedStyledFunctionBase,\n} from './types.js';\n\nconst defaultOptions: Options = {\n name: null,\n slot: null,\n};\n\nexport const styledFunction = <\n C extends AnyStyledComponent | keyof React.JSX.IntrinsicElements | React.ComponentType<any>,\n>(\n tag: C,\n options: Options = defaultOptions,\n) => {\n const { name: componentName, slot: componentSlot } = options;\n\n checkNamingConvention(componentName, componentSlot);\n\n // Here we use the `as` because when C is keyof JSX.IntrinsicElements we get `never` for the attributes generic\n // We want to account for string | number | symbol that's why we transform it to `keyof any`\n const baseStyledResolver = baseStyled(tag) as unknown as ThemedStyledFunction<C, Theme, {}, keyof any>;\n\n // Due to the recursive natura of this function, we can't type it properly\n // Since we can apply .attrs or .withConfig, we are not sure on the type of the returned function\n // @ts-expect-error explained above\n const dsStyledResolver: ThemedStyledFunctionBase<C, Theme> = (styleArg, ...expressions) => {\n /**\n * Here we apply a transformation to the expressions only.\n * Since this resolver is returning a HOC of a styled-component, the syntax support for\n * selecting the className of another styled-component is not available anymore.\n * That's why we assign it a `dsStyledComponnentId`, we will replace the component's call for\n * the corresponding id\n */\n const expressionsWithDsStyledComponentId = dsStyledComponentTransform(expressions);\n\n /**\n * Here we apply a CSS transformation to support MAGIC styled components\n * This makes it possible to use the following syntax:\n * color: neutral-100;\n * background-color: success-900;\n */\n const [styleArgWithMagic, expressionsWithMagic] = magicCssTransform(styleArg, expressionsWithDsStyledComponentId);\n\n /**\n * We coerce all the already written expressions with the default theme\n * This prevents styled components to break when a theme is not provided\n * either with the HOC or the ThemeProvider\n */\n const expressionsWithThemeCoerced = coerceWithDefaultTheme(expressionsWithMagic);\n\n if (componentName && componentSlot) {\n // Here we add the style overrides expression\n expressionsWithThemeCoerced.push(genStyleOverridesExpression(componentName, componentSlot));\n }\n\n if (componentName && componentSlot === 'root') {\n // Here we add the variant overrides from the user (only for the root slot\n expressionsWithThemeCoerced.push(genVariantOverridesExpression(componentName));\n }\n\n /**\n * Here we will fix the format of the style argument\n * We possible added some new expressions into the mix,\n * so we need to properly adjust the style arg\n */\n const numOfExpressionsAdded = expressionsWithThemeCoerced.length - expressionsWithMagic.length;\n\n const fixedStyleArg = fixStyleArg(styleArgWithMagic, numOfExpressionsAdded);\n\n // We will add autocalculated attributes to the styled component\n const [displayName, attributes] = generateAutoCalculated(options);\n\n // For each attribute function, we will call `attrs` func with it\n // This will add the attributes to the styled component\n const baseStyledResolverWithAttributes = attributes.reduce<typeof baseStyledResolver>(\n (curStyledResolver, attributeFunc) => curStyledResolver.attrs(attributeFunc),\n baseStyledResolver,\n );\n\n const Component = baseStyledResolverWithAttributes(fixedStyleArg, ...expressionsWithThemeCoerced);\n\n const ComponentWithRefsMerged = (props: OwnerInterface & InnerRefInterface<C> & { 'data-testid'?: string }) => {\n // we may or not have data-testid at this point, so we need to calculate it\n const dataTestId = props['data-testid'] ?? (displayName !== null ? displayNameToKebabCase(displayName) : '');\n // we also need to calculate dataDimsumSlot at this point\n const dataDimsumSlot = displayName !== null ? displayNameToPropCase(displayName) : '';\n // then we get the part props for this slot, and we cast it to use refs\n const partProps = getPartProps({\n ...props,\n 'data-testid': dataTestId,\n 'data-dimsum-slot': dataDimsumSlot,\n }) as {\n innerRef?: AnyStyledRef<HTMLElement>;\n };\n\n // then we merge the callbacks from the props with the ones from the part\n // this object also has all global props from the parts\n const resultingObjectWithCallbackMerged = callbackMerger(props, partProps);\n\n const mergedRef = useMemo(\n () => mergeRefs(props.innerRef, partProps.innerRef),\n [props.innerRef, partProps.innerRef],\n );\n\n // We don't want to pass the owner props to the component down the line\n const { getOwnerProps, getOwnerPropsArguments, ...restProps } = props;\n // TODO:\n // deploy the following code and see if we break something in a dedicated effort ASAP\n // let ref = undefined;\n // eslint-disable-next-line @typescript-eslint/ban-ts-comment\n // @ts-ignore : as of thue 16 may 2024, Component.target.$$typeof is undefined for non-native react components\n // eslint-disable-next-line @typescript-eslint/no-unsafe-member-access\n // if (typeof Component?.target === 'string') {\n // ref = mergedRef;\n // }\n\n const propsWithRefMerged = {\n ...restProps,\n ...resultingObjectWithCallbackMerged,\n // ref: ref,\n ref: mergedRef,\n innerRef: mergedRef,\n } as React.ComponentProps<C>;\n\n // TODO: check if we need to pass the ref to the component\n // Check $$typeof to see if it's a react-forward-ref\n // Check dsStyledComponentId to see if it's a styled component\n // Check what to do with span, div, etc.\n // Other cases should not receive ref...?\n\n return <Component {...propsWithRefMerged} />;\n };\n\n if (displayName !== null) {\n Component.displayName = displayName;\n }\n\n // eslint-disable-next-line @typescript-eslint/ban-ts-comment\n // @ts-ignore We use dsStyledComponent to access the original's component id\n ComponentWithRefsMerged.dsStyledComponentId = Component.styledComponentId as string;\n // eslint-disable-next-line @typescript-eslint/unbound-method\n ComponentWithRefsMerged.toString = Component.toString;\n\n return ComponentWithRefsMerged;\n };\n\n // Here we use arrow functions to preserve the `this` context\n const styledAttributes = {\n attrs: ((...args) => {\n baseStyledResolver.attrs(...args);\n return dsStyledResolver;\n }) as (typeof baseStyledResolver)['attrs'],\n withConfig: ((...args) => {\n baseStyledResolver.withConfig(...args);\n return dsStyledResolver;\n }) as (typeof baseStyledResolver)['withConfig'],\n };\n\n return Object.assign(dsStyledResolver, styledAttributes);\n};\n"],
5
+ "mappings": "AAAA,YAAY,WAAW;ACwJV;AArJb,SAAgB,eAAe;AAE/B,SAAS,6BAA6B;AACtC,SAAS,8BAA8B;AACvC,SAAS,6BAA6B,qCAAqC;AAC3E,SAAS,mBAAmB;AAC5B,SAAS,oBAAoB;AAC7B,SAAS,8BAA8B;AACvC,SAAS,sBAAsB;AAC/B,SAAS,iBAAiB;AAC1B,SAAS,wBAAwB,6BAA6B;AAC9D,SAAS,UAAU,kBAAkB;AACrC,SAAS,4BAA4B,yBAAyB;AAU9D,MAAM,iBAA0B;AAAA,EAC9B,MAAM;AAAA,EACN,MAAM;AACR;AAEO,MAAM,iBAAiB,CAG5B,KACA,UAAmB,mBAChB;AACH,QAAM,EAAE,MAAM,eAAe,MA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QACzB,GAAG;AAAA,QACH,GAAG;AAAA;AAAA,QAEH,KAAK;AAAA,QACL,UAAU;AAAA,MACZ;AAQA,aAAO,oBAAC,aAAW,GAAG,oBAAoB;AAAA,IAC5C;AAEA,QAAI,gBAAgB,MAAM;AACxB,gBAAU,cAAc;AAAA,IAC1B;AAIA,4BAAwB,sBAAsB,UAAU;AAExD,4BAAwB,WAAW,UAAU;AAE7C,WAAO;AAAA,EACT;AAGA,QAAM,mBAAmB;AAAA,IACvB,OAAQ,IAAI,SAAS;AACnB,yBAAmB,MAAM,GAAG,IAAI;AAChC,aAAO;AAAA,IACT;AAAA,IACA,YAAa,IAAI,SAAS;AACxB,yBAAmB,WAAW,GAAG,IAAI;AACrC,aAAO;AAAA,IACT;AAAA,EACF;AAEA,SAAO,OAAO,OAAO,kBAAkB,gBAAgB;AACzD;",
6
6
  "names": []
7
7
  }
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "version": 3,
3
3
  "sources": ["../../../../../../scripts/build/transpile/react-shim.js", "../../../src/styled/styledObject.ts"],
4
- "sourcesContent": ["import * as React from 'react';\nexport { React };\n", "import { styledFunction } from './styledFunction.js';\nimport { styled as baseStyled } from './system.js';\n\ntype PreStyledObject = {\n [TTag in keyof JSX.IntrinsicElements]: unknown;\n};\n\nexport type StyledObject = {\n [TTag in keyof JSX.IntrinsicElements]: ReturnType<typeof styledFunction<TTag>>;\n};\n\nconst keyofJsxIntrinsicElements = Object.keys(baseStyled) as (keyof JSX.IntrinsicElements)[];\n\nexport const styledObject = keyofJsxIntrinsicElements.reduce((obj, key) => {\n obj[key] = styledFunction(key);\n return obj;\n}, {} as PreStyledObject) as StyledObject;\n"],
5
- "mappings": "AAAA,YAAY,WAAW;ACAvB,SAAS,sBAAsB;AAC/B,SAAS,UAAU,kBAAkB;AAUrC,MAAM,4BAA4B,OAAO,KAAK,UAAU;AAEjD,MAAM,eAAe,0BAA0B,OAAO,CAAC,KAAK,QAAQ;AACzE,MAAI,GAAG,IAAI,eAAe,GAAG;AAC7B,SAAO;AACT,GAAG,CAAC,CAAoB;",
4
+ "sourcesContent": ["import * as React from 'react';\nexport { React };\n", "import type React from 'react';\nimport { styledFunction } from './styledFunction.js';\nimport { styled as baseStyled } from './system.js';\n\ntype PreStyledObject = {\n [TTag in keyof React.JSX.IntrinsicElements]: unknown;\n};\n\nexport type StyledObject = {\n [TTag in keyof React.JSX.IntrinsicElements]: ReturnType<typeof styledFunction<TTag>>;\n};\n\nconst keyofJsxIntrinsicElements = Object.keys(baseStyled) as (keyof React.JSX.IntrinsicElements)[];\n\nexport const styledObject = keyofJsxIntrinsicElements.reduce((obj, key) => {\n obj[key] = styledFunction(key);\n return obj;\n}, {} as PreStyledObject) as StyledObject;\n"],
5
+ "mappings": "AAAA,YAAY,WAAW;ACCvB,SAAS,sBAAsB;AAC/B,SAAS,UAAU,kBAAkB;AAUrC,MAAM,4BAA4B,OAAO,KAAK,UAAU;AAEjD,MAAM,eAAe,0BAA0B,OAAO,CAAC,KAAK,QAAQ;AACzE,MAAI,GAAG,IAAI,eAAe,GAAG;AAC7B,SAAO;AACT,GAAG,CAAC,CAAoB;",
6
6
  "names": []
7
7
  }
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "version": 3,
3
3
  "sources": ["../../../../../scripts/build/transpile/react-shim.js", "../../src/themeProviderHOC.tsx"],
4
- "sourcesContent": ["import * as React from 'react';\nexport { React };\n", "import React from 'react';\nimport { ThemeProvider } from '@xstyled/styled-components';\nimport { theme } from './theme.js';\n\nexport const themeProviderHOC = <T extends JSX.IntrinsicAttributes>(Component: React.ComponentType<T>) => {\n const WrappedComponent: React.ComponentType<T> = (props) => (\n <ThemeProvider\n theme={{\n ...theme,\n layoutMode: 'l',\n }}\n >\n <Component {...props} />\n </ThemeProvider>\n );\n return WrappedComponent;\n};\n"],
5
- "mappings": "AAAA,YAAY,WAAW;ACYjB;AAXN,SAAS,qBAAqB;AAC9B,SAAS,aAAa;AAEf,MAAM,mBAAmB,CAAoC,cAAsC;AACxG,QAAM,mBAA2C,CAAC,UAChD;AAAA,IAAC;AAAA;AAAA,MACC,OAAO;AAAA,QACL,GAAG;AAAA,QACH,YAAY;AAAA,MACd;AAAA,MAEA,8BAAC,aAAW,GAAG,OAAO;AAAA;AAAA,EACxB;AAEF,SAAO;AACT;",
4
+ "sourcesContent": ["import * as React from 'react';\nexport { React };\n", "import React from 'react';\nimport { ThemeProvider } from '@xstyled/styled-components';\nimport { theme } from './theme.js';\n\nexport const themeProviderHOC = <T extends React.JSX.IntrinsicAttributes>(Component: React.ComponentType<T>) => {\n const WrappedComponent: React.ComponentType<T> = (props) => (\n <ThemeProvider\n theme={{\n ...theme,\n layoutMode: 'l',\n }}\n >\n <Component {...props} />\n </ThemeProvider>\n );\n return WrappedComponent;\n};\n"],
5
+ "mappings": "AAAA,YAAY,WAAW;ACYjB;AAXN,SAAS,qBAAqB;AAC9B,SAAS,aAAa;AAEf,MAAM,mBAAmB,CAA0C,cAAsC;AAC9G,QAAM,mBAA2C,CAAC,UAChD;AAAA,IAAC;AAAA;AAAA,MACC,OAAO;AAAA,QACL,GAAG;AAAA,QACH,YAAY;AAAA,MACd;AAAA,MAEA,8BAAC,aAAW,GAAG,OAAO;AAAA;AAAA,EACxB;AAEF,SAAO;AACT;",
6
6
  "names": []
7
7
  }
@@ -1,17 +1,11 @@
1
1
  import * as React from "react";
2
- import {
3
- styled,
4
- typography,
5
- background,
6
- borders,
7
- sizing,
8
- space,
9
- boxShadows,
10
- flexboxes,
11
- layout,
12
- color
13
- } from "./index.js";
14
- import { compose } from "@xstyled/system";
2
+ import { boxShadow as boxShadows, compose, flexboxes, layout, typography } from "@xstyled/system";
3
+ import { styled } from "./styled/styled.js";
4
+ import { background } from "./styled/system-utilities/background.js";
5
+ import { borders } from "./styled/system-utilities/border.js";
6
+ import { color } from "./styled/system-utilities/color.js";
7
+ import { sizing } from "./styled/system-utilities/sizing.js";
8
+ import { space } from "./styled/system-utilities/space.js";
15
9
  const XStyledWrapper = styled("div")`
16
10
  ${typography}
17
11
  ${layout}
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "version": 3,
3
3
  "sources": ["../../../../../scripts/build/transpile/react-shim.js", "../../src/xStyledWrapper.tsx"],
4
- "sourcesContent": ["import * as React from 'react';\nexport { React };\n", "import {\n styled,\n typography,\n background,\n borders,\n sizing,\n space,\n boxShadows,\n flexboxes,\n layout,\n color,\n} from './index.js';\nimport type {} from '@xstyled/util';\nimport type {} from '@xstyled/system';\nimport { compose } from '@xstyled/system';\n\nexport const XStyledWrapper = styled('div')`\n ${typography}\n ${layout}\n ${space}\n ${sizing}\n ${background}\n ${borders}\n ${boxShadows}\n ${flexboxes}\n ${color}\n`;\n\nexport const xStyledCommonProps = compose(\n typography,\n background,\n borders,\n sizing,\n space,\n boxShadows,\n flexboxes,\n layout,\n color,\n);\n\nexport default XStyledWrapper;\n"],
5
- "mappings": "AAAA,YAAY,WAAW;ACAvB;AAAA,EACE;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,OACK;AAGP,SAAS,eAAe;AAEjB,MAAM,iBAAiB,OAAO,KAAK;AAAA,IACtC,UAAU;AAAA,IACV,MAAM;AAAA,IACN,KAAK;AAAA,IACL,MAAM;AAAA,IACN,UAAU;AAAA,IACV,OAAO;AAAA,IACP,UAAU;AAAA,IACV,SAAS;AAAA,IACT,KAAK;AAAA;AAGF,MAAM,qBAAqB;AAAA,EAChC;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AACF;AAEA,IAAO,yBAAQ;",
4
+ "sourcesContent": ["import * as React from 'react';\nexport { React };\n", "import type {} from '@xstyled/system';\nimport { boxShadow as boxShadows, compose, flexboxes, layout, typography } from '@xstyled/system';\nimport type {} from '@xstyled/util';\nimport { styled } from './styled/styled.js';\nimport { background } from './styled/system-utilities/background.js';\nimport { borders } from './styled/system-utilities/border.js';\nimport { color } from './styled/system-utilities/color.js';\nimport { sizing } from './styled/system-utilities/sizing.js';\nimport { space } from './styled/system-utilities/space.js';\n\nexport const XStyledWrapper = styled('div')`\n ${typography}\n ${layout}\n ${space}\n ${sizing}\n ${background}\n ${borders}\n ${boxShadows}\n ${flexboxes}\n ${color}\n`;\n\nexport const xStyledCommonProps = compose(\n typography,\n background,\n borders,\n sizing,\n space,\n boxShadows,\n flexboxes,\n layout,\n color,\n);\n\nexport default XStyledWrapper;\n"],
5
+ "mappings": "AAAA,YAAY,WAAW;ACCvB,SAAS,aAAa,YAAY,SAAS,WAAW,QAAQ,kBAAkB;AAEhF,SAAS,cAAc;AACvB,SAAS,kBAAkB;AAC3B,SAAS,eAAe;AACxB,SAAS,aAAa;AACtB,SAAS,cAAc;AACvB,SAAS,aAAa;AAEf,MAAM,iBAAiB,OAAO,KAAK;AAAA,IACtC,UAAU;AAAA,IACV,MAAM;AAAA,IACN,KAAK;AAAA,IACL,MAAM;AAAA,IACN,UAAU;AAAA,IACV,OAAO;AAAA,IACP,UAAU;AAAA,IACV,SAAS;AAAA,IACT,KAAK;AAAA;AAGF,MAAM,qBAAqB;AAAA,EAChC;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AACF;AAEA,IAAO,yBAAQ;",
6
6
  "names": []
7
7
  }
@@ -1,5 +1,5 @@
1
1
  /// <reference types="react" />
2
- export declare const styled: (<C extends import("react").ComponentType<any> | keyof JSX.IntrinsicElements | import("styled-components").AnyStyledComponent>(tag: C, options?: import("./types.js").Options) => import("./types.js").ThemedStyledFunctionBase<C, import("./types.js").Theme, {}, never> & {
2
+ export declare const styled: (<C extends keyof import("react").JSX.IntrinsicElements | import("react").ComponentType<any> | import("styled-components").AnyStyledComponent>(tag: C, options?: import("./types.js").Options) => import("./types.js").ThemedStyledFunctionBase<C, import("./types.js").Theme, {}, never> & {
3
3
  attrs: <U, NewA extends Partial<import("styled-components").StyledComponentPropsWithRef<C> & U> & {
4
4
  [others: string]: any;
5
5
  } = {}>(attrs: NewA | ((props: import("styled-components").ThemedStyledProps<import("styled-components").StyledComponentPropsWithRef<C> & U, import("./types.js").Theme>) => NewA)) => import("styled-components").ThemedStyledFunction<C, import("./types.js").Theme, {} & NewA, string | number | symbol | keyof NewA>;
@@ -1,7 +1,7 @@
1
+ import React from 'react';
1
2
  import type { AnyStyledComponent, ThemedStyledFunction } from 'styled-components';
2
3
  import type { Options, Theme, ThemedStyledFunctionBase } from './types.js';
3
- import React from 'react';
4
- export declare const styledFunction: <C extends React.ComponentType<any> | keyof JSX.IntrinsicElements | AnyStyledComponent>(tag: C, options?: Options) => ThemedStyledFunctionBase<C, Theme, {}, never> & {
4
+ export declare const styledFunction: <C extends keyof React.JSX.IntrinsicElements | React.ComponentType<any> | AnyStyledComponent>(tag: C, options?: Options) => ThemedStyledFunctionBase<C, Theme, {}, never> & {
5
5
  attrs: <U, NewA extends Partial<import("styled-components").StyledComponentPropsWithRef<C> & U> & {
6
6
  [others: string]: any;
7
7
  } = {}>(attrs: NewA | ((props: import("styled-components").ThemedStyledProps<import("styled-components").StyledComponentPropsWithRef<C> & U, Theme>) => NewA)) => ThemedStyledFunction<C, Theme, {} & NewA, string | number | symbol | keyof NewA>;
@@ -1,5 +1,6 @@
1
+ import type React from 'react';
1
2
  import { styledFunction } from './styledFunction.js';
2
3
  export type StyledObject = {
3
- [TTag in keyof JSX.IntrinsicElements]: ReturnType<typeof styledFunction<TTag>>;
4
+ [TTag in keyof React.JSX.IntrinsicElements]: ReturnType<typeof styledFunction<TTag>>;
4
5
  };
5
6
  export declare const styledObject: StyledObject;
@@ -28,8 +28,8 @@ export type PropsWithTheme<T = Record<string, unknown>> = T & {
28
28
  theme: Theme;
29
29
  };
30
30
  type ComponentInnerRef<T extends ElementType> = T extends new (props: infer P) => React.Component<any, any> ? Ref<InstanceType<T>> | undefined : React.PropsWithRef<React.ComponentProps<T>>['ref'];
31
- export type StyledComponentInnerRef<C extends keyof JSX.IntrinsicElements | React.ComponentType<any>> = C extends AnyStyledComponent ? ComponentInnerRef<StyledComponentInnerComponent<C>> : ComponentInnerRef<C>;
32
- export interface ThemedStyledFunctionBase<C extends keyof JSX.IntrinsicElements | React.ComponentType<any>, T extends object, O extends object = {}, A extends keyof any = never> {
31
+ export type StyledComponentInnerRef<C extends keyof React.JSX.IntrinsicElements | React.ComponentType<any>> = C extends AnyStyledComponent ? ComponentInnerRef<StyledComponentInnerComponent<C>> : ComponentInnerRef<C>;
32
+ export interface ThemedStyledFunctionBase<C extends keyof React.JSX.IntrinsicElements | React.ComponentType<any>, T extends object, O extends object = {}, A extends keyof any = never> {
33
33
  <U extends object>(first: StyleArg<ThemedStyledProps<StyledComponentPropsWithRef<C> & O & U & OwnerInterface & InnerRefInterface<C>, T>>, ...rest: Expressions<ThemedStyledProps<StyledComponentPropsWithRef<C> & O & U & OwnerInterface & InnerRefInterface<C>, T>>): StyledComponent<C, T, O & U & OwnerInterface & InnerRefInterface<C>, A>;
34
34
  }
35
35
  export type AttrsFunc<T extends object = Record<string, unknown>> = (props: StyledComponentPropsWithRef<StyledComponentInnerComponent<React.ComponentType<T>>>) => Partial<StyledComponentPropsWithRef<StyledComponentInnerComponent<any>>>;
@@ -39,7 +39,7 @@ export type InternalAttrsFunc<T extends object = Record<string, unknown>> = (pro
39
39
  options: Options;
40
40
  displayName: string | null;
41
41
  }) => Partial<StyledComponentPropsWithRef<StyledComponentInnerComponent<any>>>;
42
- export interface InnerRefInterface<C extends keyof JSX.IntrinsicElements | React.ComponentType<any>> {
42
+ export interface InnerRefInterface<C extends keyof React.JSX.IntrinsicElements | React.ComponentType<any>> {
43
43
  innerRef?: StyledComponentInnerRef<C>;
44
44
  ref?: never;
45
45
  }
@@ -1,2 +1,2 @@
1
1
  import React from 'react';
2
- export declare const themeProviderHOC: <T extends JSX.IntrinsicAttributes>(Component: React.ComponentType<T>) => React.FunctionComponent<T>;
2
+ export declare const themeProviderHOC: <T extends React.JSX.IntrinsicAttributes>(Component: React.ComponentType<T>) => React.FunctionComponent<T>;
@@ -1 +1 @@
1
- export declare const useGetLayoutMode: () => "xs" | "s" | "m" | "l" | undefined;
1
+ export declare const useGetLayoutMode: () => "l" | "m" | "s" | "xs" | undefined;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@elliemae/ds-system",
3
- "version": "3.48.2-rc.0",
3
+ "version": "3.49.0-beta.2",
4
4
  "license": "MIT",
5
5
  "description": "ICE MT - Dimsum - System",
6
6
  "files": [
@@ -101,7 +101,7 @@
101
101
  "@elliemae/pui-cli": "9.0.0-next.50",
102
102
  "@elliemae/pui-theme": "~2.10.0",
103
103
  "styled-components": "~5.3.9",
104
- "@elliemae/ds-monorepo-devops": "3.48.2-rc.0"
104
+ "@elliemae/ds-monorepo-devops": "3.49.0-beta.2"
105
105
  },
106
106
  "peerDependencies": {
107
107
  "@elliemae/pui-theme": "~2.10.0",