solid-js 1.9.6 → 1.9.8

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.
Files changed (51) hide show
  1. package/dist/dev.cjs +26 -15
  2. package/dist/dev.js +334 -564
  3. package/dist/server.cjs +3 -1
  4. package/dist/server.js +83 -178
  5. package/dist/solid.cjs +26 -15
  6. package/dist/solid.js +290 -493
  7. package/h/dist/h.js +9 -40
  8. package/h/jsx-runtime/dist/jsx.js +1 -1
  9. package/h/jsx-runtime/types/index.d.ts +8 -11
  10. package/h/jsx-runtime/types/jsx.d.ts +246 -234
  11. package/h/types/hyperscript.d.ts +11 -11
  12. package/html/dist/html.js +94 -219
  13. package/html/types/lit.d.ts +33 -52
  14. package/package.json +3 -3
  15. package/store/dist/dev.cjs +9 -5
  16. package/store/dist/dev.js +50 -126
  17. package/store/dist/server.js +8 -20
  18. package/store/dist/store.cjs +9 -5
  19. package/store/dist/store.js +47 -117
  20. package/store/types/index.d.ts +7 -21
  21. package/store/types/modifiers.d.ts +3 -6
  22. package/store/types/mutable.d.ts +2 -5
  23. package/store/types/server.d.ts +5 -25
  24. package/store/types/store.d.ts +61 -218
  25. package/types/index.d.ts +11 -78
  26. package/types/jsx.d.ts +245 -229
  27. package/types/reactive/array.d.ts +4 -12
  28. package/types/reactive/observable.d.ts +16 -22
  29. package/types/reactive/scheduler.d.ts +6 -9
  30. package/types/reactive/signal.d.ts +145 -236
  31. package/types/render/Suspense.d.ts +5 -5
  32. package/types/render/component.d.ts +37 -73
  33. package/types/render/flow.d.ts +31 -43
  34. package/types/render/hydration.d.ts +15 -15
  35. package/types/server/index.d.ts +2 -57
  36. package/types/server/reactive.d.ts +45 -76
  37. package/types/server/rendering.d.ts +98 -169
  38. package/universal/dist/dev.js +12 -28
  39. package/universal/dist/universal.js +12 -28
  40. package/universal/types/index.d.ts +2 -3
  41. package/universal/types/universal.d.ts +3 -2
  42. package/web/dist/dev.cjs +89 -6
  43. package/web/dist/dev.js +174 -646
  44. package/web/dist/server.cjs +90 -5
  45. package/web/dist/server.js +194 -647
  46. package/web/dist/web.cjs +89 -6
  47. package/web/dist/web.js +172 -634
  48. package/web/storage/dist/storage.js +3 -3
  49. package/web/types/core.d.ts +1 -9
  50. package/web/types/index.d.ts +11 -31
  51. package/web/types/server-mock.d.ts +32 -47
@@ -4,9 +4,28 @@ var solidJs = require('solid-js');
4
4
  var seroval = require('seroval');
5
5
  var web = require('seroval-plugins/web');
6
6
 
7
- const booleans = ["allowfullscreen", "async", "autofocus", "autoplay", "checked", "controls", "default", "disabled", "formnovalidate", "hidden", "indeterminate", "inert", "ismap", "loop", "multiple", "muted", "nomodule", "novalidate", "open", "playsinline", "readonly", "required", "reversed", "seamless", "selected"];
7
+ const booleans = ["allowfullscreen", "async", "alpha",
8
+ "autofocus",
9
+ "autoplay", "checked", "controls", "default", "disabled", "formnovalidate", "hidden",
10
+ "indeterminate", "inert",
11
+ "ismap", "loop", "multiple", "muted", "nomodule", "novalidate", "open", "playsinline", "readonly", "required", "reversed", "seamless",
12
+ "selected", "adauctionheaders",
13
+ "browsingtopics",
14
+ "credentialless",
15
+ "defaultchecked", "defaultmuted", "defaultselected", "defer", "disablepictureinpicture", "disableremoteplayback", "preservespitch",
16
+ "shadowrootclonable", "shadowrootcustomelementregistry",
17
+ "shadowrootdelegatesfocus", "shadowrootserializable",
18
+ "sharedstoragewritable"
19
+ ];
8
20
  const BooleanAttributes = /*#__PURE__*/new Set(booleans);
9
- const Properties = /*#__PURE__*/new Set(["className", "value", "readOnly", "noValidate", "formNoValidate", "isMap", "noModule", "playsInline", ...booleans]);
21
+ const Properties = /*#__PURE__*/new Set([
22
+ "className", "value",
23
+ "readOnly", "noValidate", "formNoValidate", "isMap", "noModule", "playsInline", "adAuctionHeaders",
24
+ "allowFullscreen", "browsingTopics",
25
+ "defaultChecked", "defaultMuted", "defaultSelected", "disablePictureInPicture", "disableRemotePlayback", "preservesPitch", "shadowRootClonable", "shadowRootCustomElementRegistry",
26
+ "shadowRootDelegatesFocus", "shadowRootSerializable",
27
+ "sharedStorageWritable",
28
+ ...booleans]);
10
29
  const ChildProperties = /*#__PURE__*/new Set(["innerHTML", "textContent", "innerText", "children"]);
11
30
  const Aliases = /*#__PURE__*/Object.assign(Object.create(null), {
12
31
  className: "class",
@@ -39,6 +58,62 @@ const PropAliases = /*#__PURE__*/Object.assign(Object.create(null), {
39
58
  $: "readOnly",
40
59
  INPUT: 1,
41
60
  TEXTAREA: 1
61
+ },
62
+ adauctionheaders: {
63
+ $: "adAuctionHeaders",
64
+ IFRAME: 1
65
+ },
66
+ allowfullscreen: {
67
+ $: "allowFullscreen",
68
+ IFRAME: 1
69
+ },
70
+ browsingtopics: {
71
+ $: "browsingTopics",
72
+ IMG: 1
73
+ },
74
+ defaultchecked: {
75
+ $: "defaultChecked",
76
+ INPUT: 1
77
+ },
78
+ defaultmuted: {
79
+ $: "defaultMuted",
80
+ AUDIO: 1,
81
+ VIDEO: 1
82
+ },
83
+ defaultselected: {
84
+ $: "defaultSelected",
85
+ OPTION: 1
86
+ },
87
+ disablepictureinpicture: {
88
+ $: "disablePictureInPicture",
89
+ VIDEO: 1
90
+ },
91
+ disableremoteplayback: {
92
+ $: "disableRemotePlayback",
93
+ AUDIO: 1,
94
+ VIDEO: 1
95
+ },
96
+ preservespitch: {
97
+ $: "preservesPitch",
98
+ AUDIO: 1,
99
+ VIDEO: 1
100
+ },
101
+ shadowrootclonable: {
102
+ $: "shadowRootClonable",
103
+ TEMPLATE: 1
104
+ },
105
+ shadowrootdelegatesfocus: {
106
+ $: "shadowRootDelegatesFocus",
107
+ TEMPLATE: 1
108
+ },
109
+ shadowrootserializable: {
110
+ $: "shadowRootSerializable",
111
+ TEMPLATE: 1
112
+ },
113
+ sharedstoragewritable: {
114
+ $: "sharedStorageWritable",
115
+ IFRAME: 1,
116
+ IMG: 1
42
117
  }
43
118
  });
44
119
  function getPropAlias(prop, tagName) {
@@ -55,7 +130,9 @@ const SVGNamespace = {
55
130
  xlink: "http://www.w3.org/1999/xlink",
56
131
  xml: "http://www.w3.org/XML/1998/namespace"
57
132
  };
58
- const DOMElements = /*#__PURE__*/new Set(["html", "base", "head", "link", "meta", "style", "title", "body", "address", "article", "aside", "footer", "header", "main", "nav", "section", "body", "blockquote", "dd", "div", "dl", "dt", "figcaption", "figure", "hr", "li", "ol", "p", "pre", "ul", "a", "abbr", "b", "bdi", "bdo", "br", "cite", "code", "data", "dfn", "em", "i", "kbd", "mark", "q", "rp", "rt", "ruby", "s", "samp", "small", "span", "strong", "sub", "sup", "time", "u", "var", "wbr", "area", "audio", "img", "map", "track", "video", "embed", "iframe", "object", "param", "picture", "portal", "source", "svg", "math", "canvas", "noscript", "script", "del", "ins", "caption", "col", "colgroup", "table", "tbody", "td", "tfoot", "th", "thead", "tr", "button", "datalist", "fieldset", "form", "input", "label", "legend", "meter", "optgroup", "option", "output", "progress", "select", "textarea", "details", "dialog", "menu", "summary", "details", "slot", "template", "acronym", "applet", "basefont", "bgsound", "big", "blink", "center", "content", "dir", "font", "frame", "frameset", "hgroup", "image", "keygen", "marquee", "menuitem", "nobr", "noembed", "noframes", "plaintext", "rb", "rtc", "shadow", "spacer", "strike", "tt", "xmp", "a", "abbr", "acronym", "address", "applet", "area", "article", "aside", "audio", "b", "base", "basefont", "bdi", "bdo", "bgsound", "big", "blink", "blockquote", "body", "br", "button", "canvas", "caption", "center", "cite", "code", "col", "colgroup", "content", "data", "datalist", "dd", "del", "details", "dfn", "dialog", "dir", "div", "dl", "dt", "em", "embed", "fieldset", "figcaption", "figure", "font", "footer", "form", "frame", "frameset", "head", "header", "hgroup", "hr", "html", "i", "iframe", "image", "img", "input", "ins", "kbd", "keygen", "label", "legend", "li", "link", "main", "map", "mark", "marquee", "menu", "menuitem", "meta", "meter", "nav", "nobr", "noembed", "noframes", "noscript", "object", "ol", "optgroup", "option", "output", "p", "param", "picture", "plaintext", "portal", "pre", "progress", "q", "rb", "rp", "rt", "rtc", "ruby", "s", "samp", "script", "section", "select", "shadow", "slot", "small", "source", "spacer", "span", "strike", "strong", "style", "sub", "summary", "sup", "table", "tbody", "td", "template", "textarea", "tfoot", "th", "thead", "time", "title", "tr", "track", "tt", "u", "ul", "var", "video", "wbr", "xmp", "input", "h1", "h2", "h3", "h4", "h5", "h6"]);
133
+ const DOMElements = /*#__PURE__*/new Set(["html", "base", "head", "link", "meta", "style", "title", "body", "address", "article", "aside", "footer", "header", "main", "nav", "section", "body", "blockquote", "dd", "div", "dl", "dt", "figcaption", "figure", "hr", "li", "ol", "p", "pre", "ul", "a", "abbr", "b", "bdi", "bdo", "br", "cite", "code", "data", "dfn", "em", "i", "kbd", "mark", "q", "rp", "rt", "ruby", "s", "samp", "small", "span", "strong", "sub", "sup", "time", "u", "var", "wbr", "area", "audio", "img", "map", "track", "video", "embed", "iframe", "object", "param", "picture", "portal", "source", "svg", "math", "canvas", "noscript", "script", "del", "ins", "caption", "col", "colgroup", "table", "tbody", "td", "tfoot", "th", "thead", "tr", "button", "datalist", "fieldset", "form", "input", "label", "legend", "meter", "optgroup", "option", "output", "progress", "select", "textarea", "details", "dialog", "menu", "summary", "details", "slot", "template", "acronym", "applet", "basefont", "bgsound", "big", "blink", "center", "content", "dir", "font", "frame", "frameset", "hgroup", "image", "keygen", "marquee", "menuitem", "nobr", "noembed", "noframes", "plaintext", "rb", "rtc", "shadow", "spacer", "strike", "tt", "xmp", "a", "abbr", "acronym", "address", "applet", "area", "article", "aside", "audio", "b", "base", "basefont", "bdi", "bdo", "bgsound", "big", "blink", "blockquote", "body", "br", "button", "canvas", "caption", "center", "cite", "code", "col", "colgroup", "content", "data", "datalist", "dd", "del", "details", "dfn", "dialog", "dir", "div", "dl", "dt", "em", "embed", "fieldset", "figcaption", "figure", "font", "footer", "form", "frame", "frameset", "head", "header", "hgroup", "hr", "html", "i", "iframe", "image", "img", "input", "ins", "kbd", "keygen", "label", "legend", "li", "link", "main", "map", "mark", "marquee", "menu", "menuitem", "meta", "meter", "nav", "nobr", "noembed", "noframes", "noscript", "object", "ol", "optgroup", "option", "output", "p", "param", "picture", "plaintext", "portal", "pre", "progress", "q", "rb", "rp", "rt", "rtc", "ruby", "s", "samp", "script", "section", "select", "shadow", "slot", "small", "source", "spacer", "span", "strike", "strong", "style", "sub", "summary", "sup", "table", "tbody", "td", "template", "textarea", "tfoot", "th", "thead", "time", "title", "tr", "track", "tt", "u", "ul", "var", "video", "wbr", "xmp", "input", "h1", "h2", "h3", "h4", "h5", "h6",
134
+ "webview",
135
+ "isindex", "listing", "multicol", "nextid", "noindex", "search"]);
59
136
 
60
137
  const memo = fn => solidJs.createMemo(() => fn());
61
138
 
@@ -70,7 +147,7 @@ function createSerializer({
70
147
  }) {
71
148
  return new seroval.Serializer({
72
149
  scopeId,
73
- plugins: [
150
+ plugins: [web.AbortSignalPlugin,
74
151
  web.CustomEventPlugin, web.DOMExceptionPlugin, web.EventPlugin,
75
152
  web.FormDataPlugin, web.HeadersPlugin, web.ReadableStreamPlugin, web.RequestPlugin, web.ResponsePlugin, web.URLSearchParamsPlugin, web.URLPlugin],
76
153
  globalIdentifier: GLOBAL_IDENTIFIER,
@@ -400,11 +477,17 @@ function ssrStyle(value) {
400
477
  const v = value[s];
401
478
  if (v != undefined) {
402
479
  if (i) result += ";";
403
- result += `${s}:${escape(v, true)}`;
480
+ const r = escape(v, true);
481
+ if (r != undefined && r !== "undefined") {
482
+ result += `${s}:${r}`;
483
+ }
404
484
  }
405
485
  }
406
486
  return result;
407
487
  }
488
+ function ssrStyleProperty(name, value) {
489
+ return value != null ? name + value : "";
490
+ }
408
491
  function ssrElement(tag, props, children, needsId) {
409
492
  if (props == null) props = {};else if (typeof props === "function") props = props();
410
493
  const skipChildren = VOID_ELEMENTS.test(tag);
@@ -459,6 +542,7 @@ function escape(s, attr) {
459
542
  if (t !== "string") {
460
543
  if (!attr && t === "function") return escape(s());
461
544
  if (!attr && Array.isArray(s)) {
545
+ s = s.slice();
462
546
  for (let i = 0; i < s.length; i++) s[i] = escape(s[i]);
463
547
  return s;
464
548
  }
@@ -797,6 +881,7 @@ exports.ssrElement = ssrElement;
797
881
  exports.ssrHydrationKey = ssrHydrationKey;
798
882
  exports.ssrSpread = ssrSpread;
799
883
  exports.ssrStyle = ssrStyle;
884
+ exports.ssrStyleProperty = ssrStyleProperty;
800
885
  exports.style = notSup;
801
886
  exports.template = notSup;
802
887
  exports.useAssets = useAssets;