@elmethis/qwik 0.0.26 → 0.0.27

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.
@@ -774,7 +774,7 @@ const ElmShikiHighlighter = component$(({ code: code2, language = "txt" }) => {
774
774
  dangerouslySetInnerHTML: rawHtml.value
775
775
  });
776
776
  });
777
- const ElmCodeBlock = component$(({ code: code2, language = "txt", caption: caption2, margin }) => {
777
+ const ElmCodeBlock = component$(({ code: code2, language = "txt", caption: caption2, style }) => {
778
778
  const timerId = useSignal(null);
779
779
  const copyToClipboard = $(async () => {
780
780
  if (timerId.value !== null) {
@@ -790,9 +790,7 @@ const ElmCodeBlock = component$(({ code: code2, language = "txt", caption: capti
790
790
  });
791
791
  return /* @__PURE__ */ jsxs("figure", {
792
792
  class: styles$z["code-block"],
793
- style: {
794
- margin
795
- },
793
+ style,
796
794
  children: [
797
795
  /* @__PURE__ */ jsx("span", {
798
796
  class: styles$z["language-icon"],
@@ -867,31 +865,31 @@ const ElmParallax = component$(({ images }) => {
867
865
  ]
868
866
  });
869
867
  });
870
- const toggle = "_toggle_nwv84_1";
871
- const summary = "_summary_nwv84_14";
872
- const content$2 = "_content_nwv84_60";
873
- const footer = "_footer_nwv84_80";
868
+ const toggle = "_toggle_pbyu8_1";
869
+ const summary = "_summary_pbyu8_14";
870
+ const content$2 = "_content_pbyu8_60";
871
+ const footer = "_footer_pbyu8_80";
874
872
  const styles$s = {
875
873
  toggle,
876
- "toggle-closed": "_toggle-closed_nwv84_7",
877
- "toggle-open": "_toggle-open_nwv84_10",
874
+ "toggle-closed": "_toggle-closed_pbyu8_7",
875
+ "toggle-open": "_toggle-open_pbyu8_10",
878
876
  summary,
879
- "summary-open": "_summary-open_nwv84_29",
880
- "summary-closed": "_summary-closed_nwv84_33",
881
- "chevron-icon": "_chevron-icon_nwv84_37",
882
- "chevron-icon-open": "_chevron-icon-open_nwv84_40",
883
- "chevron-icon-closed": "_chevron-icon-closed_nwv84_43",
884
- "plus-icon": "_plus-icon_nwv84_47",
885
- "plus-icon-open": "_plus-icon-open_nwv84_53",
886
- "plus-icon-closed": "_plus-icon-closed_nwv84_56",
877
+ "summary-open": "_summary-open_pbyu8_29",
878
+ "summary-closed": "_summary-closed_pbyu8_33",
879
+ "chevron-icon": "_chevron-icon_pbyu8_37",
880
+ "chevron-icon-open": "_chevron-icon-open_pbyu8_40",
881
+ "chevron-icon-closed": "_chevron-icon-closed_pbyu8_43",
882
+ "plus-icon": "_plus-icon_pbyu8_47",
883
+ "plus-icon-open": "_plus-icon-open_pbyu8_53",
884
+ "plus-icon-closed": "_plus-icon-closed_pbyu8_56",
887
885
  content: content$2,
888
- "content-open": "_content-open_nwv84_73",
889
- "content-closed": "_content-closed_nwv84_76",
886
+ "content-open": "_content-open_pbyu8_73",
887
+ "content-closed": "_content-closed_pbyu8_76",
890
888
  footer,
891
- "footer-line": "_footer-line_nwv84_99",
892
- "footer-cross-icon": "_footer-cross-icon_nwv84_105"
889
+ "footer-line": "_footer-line_pbyu8_99",
890
+ "footer-cross-icon": "_footer-cross-icon_pbyu8_105"
893
891
  };
894
- const ElmToggle = component$(({ summary: summary2 }) => {
892
+ const ElmToggle = component$(({ summary: summary2, style }) => {
895
893
  const isOpen = useSignal(false);
896
894
  const toggle2 = $(() => {
897
895
  isOpen.value = !isOpen.value;
@@ -904,6 +902,7 @@ const ElmToggle = component$(({ summary: summary2 }) => {
904
902
  [styles$s["toggle-closed"]]: !isOpen.value
905
903
  }
906
904
  ],
905
+ style,
907
906
  children: [
908
907
  /* @__PURE__ */ jsxs("div", {
909
908
  class: [
@@ -2174,17 +2173,17 @@ const ElmToggleTheme = component$(({ size = "2rem" }) => {
2174
2173
  })
2175
2174
  });
2176
2175
  });
2177
- const image$1 = "_image_5s2ag_11";
2178
- const fallback = "_fallback_5s2ag_33";
2176
+ const image$1 = "_image_sf1wj_12";
2177
+ const fallback = "_fallback_sf1wj_34";
2179
2178
  const styles$h = {
2180
- "block-image": "_block-image_5s2ag_1",
2181
- "image-container": "_image-container_5s2ag_11",
2179
+ "block-image": "_block-image_sf1wj_1",
2180
+ "image-container": "_image-container_sf1wj_12",
2182
2181
  image: image$1,
2183
2182
  fallback,
2184
- "caption-box": "_caption-box_5s2ag_43",
2185
- "modal-container": "_modal-container_5s2ag_55"
2183
+ "caption-box": "_caption-box_sf1wj_44",
2184
+ "modal-container": "_modal-container_sf1wj_56"
2186
2185
  };
2187
- const ElmBlockImage = component$(({ src, alt, caption: caption2, width, height, enableModal = true }) => {
2186
+ const ElmBlockImage = component$(({ src, alt, caption: caption2, width, height, enableModal = true, srcset, sizes, style }) => {
2188
2187
  const isLoading = useSignal(true);
2189
2188
  const isShowModal = useSignal(false);
2190
2189
  const handleImageLoad = $(() => {
@@ -2199,6 +2198,8 @@ const ElmBlockImage = component$(({ src, alt, caption: caption2, width, height,
2199
2198
  class: styles$h.image,
2200
2199
  src,
2201
2200
  alt: alt ?? caption2 ?? "Image",
2201
+ srcset,
2202
+ sizes,
2202
2203
  width,
2203
2204
  height,
2204
2205
  onLoad$: handleImageLoad,
@@ -2219,6 +2220,7 @@ const ElmBlockImage = component$(({ src, alt, caption: caption2, width, height,
2219
2220
  });
2220
2221
  return /* @__PURE__ */ jsxs("figure", {
2221
2222
  class: styles$h["block-image"],
2223
+ style,
2222
2224
  children: [
2223
2225
  /* @__PURE__ */ jsxs("div", {
2224
2226
  class: styles$h["image-container"],
@@ -2260,18 +2262,18 @@ const ElmBlockImage = component$(({ src, alt, caption: caption2, width, height,
2260
2262
  ]
2261
2263
  });
2262
2264
  });
2263
- const file = "_file_14a0w_1";
2265
+ const file = "_file_eqa3m_1";
2264
2266
  const styles$g = {
2265
2267
  file,
2266
- "file-size": "_file-size_14a0w_16",
2267
- "download-icon": "_download-icon_14a0w_21"
2268
+ "file-size": "_file-size_eqa3m_16",
2269
+ "download-icon": "_download-icon_eqa3m_21"
2268
2270
  };
2269
2271
  function getLastPathSegmentWithoutQueryOrHash(urlString) {
2270
2272
  const cleanedUrl = urlString.split(/[?#]/)[0];
2271
2273
  const pathSegments = cleanedUrl.split("/").filter(Boolean);
2272
2274
  return pathSegments.length > 0 ? pathSegments[pathSegments.length - 1] : null;
2273
2275
  }
2274
- const ElmFile = component$(({ name, src, filesize }) => {
2276
+ const ElmFile = component$(({ name, src, filesize, style }) => {
2275
2277
  const downloadFile = $(async () => {
2276
2278
  let link2;
2277
2279
  try {
@@ -2290,6 +2292,7 @@ const ElmFile = component$(({ name, src, filesize }) => {
2290
2292
  });
2291
2293
  return /* @__PURE__ */ jsxs("div", {
2292
2294
  class: styles$g.file,
2295
+ style,
2293
2296
  children: [
2294
2297
  /* @__PURE__ */ jsx("div", {
2295
2298
  children: /* @__PURE__ */ jsx(ElmMdiIcon, {
@@ -2319,13 +2322,13 @@ const ElmFile = component$(({ name, src, filesize }) => {
2319
2322
  ]
2320
2323
  });
2321
2324
  });
2322
- const bookmark = "_bookmark_rgq1s_1";
2323
- const container$1 = "_container_rgq1s_19";
2324
- const image = "_image_rgq1s_32";
2325
- const content$1 = "_content_rgq1s_53";
2326
- const title = "_title_rgq1s_73";
2327
- const description = "_description_rgq1s_76";
2328
- const link = "_link_rgq1s_80";
2325
+ const bookmark = "_bookmark_xxvle_1";
2326
+ const container$1 = "_container_xxvle_20";
2327
+ const image = "_image_xxvle_33";
2328
+ const content$1 = "_content_xxvle_54";
2329
+ const title = "_title_xxvle_74";
2330
+ const description = "_description_xxvle_77";
2331
+ const link = "_link_xxvle_81";
2329
2332
  const styles$f = {
2330
2333
  bookmark,
2331
2334
  container: container$1,
@@ -2335,7 +2338,7 @@ const styles$f = {
2335
2338
  description,
2336
2339
  link
2337
2340
  };
2338
- const ElmBookmark = component$(({ url, image: image2, title: title2, description: description2, favicon }) => {
2341
+ const ElmBookmark = component$(({ url, image: image2, title: title2, description: description2, favicon, style }) => {
2339
2342
  const isError = useSignal(false);
2340
2343
  const handleImageOnError = $(() => {
2341
2344
  isError.value = true;
@@ -2346,6 +2349,7 @@ const ElmBookmark = component$(({ url, image: image2, title: title2, description
2346
2349
  };
2347
2350
  return /* @__PURE__ */ jsx("div", {
2348
2351
  class: styles$f.bookmark,
2352
+ style,
2349
2353
  children: /* @__PURE__ */ jsxs("a", {
2350
2354
  class: styles$f.container,
2351
2355
  href: url,
@@ -2511,21 +2515,22 @@ const ElmPageTop = component$(({ position = "right" }) => {
2511
2515
  ]
2512
2516
  });
2513
2517
  });
2514
- const blockquote = "_blockquote_b5jd8_1";
2515
- const body = "_body_b5jd8_18";
2516
- const icon = "_icon_b5jd8_23";
2518
+ const blockquote = "_blockquote_1s60i_1";
2519
+ const body = "_body_1s60i_19";
2520
+ const icon = "_icon_1s60i_24";
2517
2521
  const styles$c = {
2518
2522
  blockquote,
2519
2523
  body,
2520
2524
  icon
2521
2525
  };
2522
- const ElmBlockQuote = component$(({ cite }) => {
2526
+ const ElmBlockQuote = component$(({ cite, style }) => {
2523
2527
  return /* @__PURE__ */ jsxs("blockquote", {
2524
2528
  class: [
2525
2529
  styles$c.blockquote,
2526
2530
  textStyles.text
2527
2531
  ],
2528
2532
  cite,
2533
+ style,
2529
2534
  children: [
2530
2535
  /* @__PURE__ */ jsx("div", {
2531
2536
  class: styles$c.icon,
@@ -2552,9 +2557,9 @@ const ElmBlockQuote = component$(({ cite }) => {
2552
2557
  ]
2553
2558
  });
2554
2559
  });
2555
- const callout = "_callout_1d8l2_1";
2556
- const header = "_header_1d8l2_25";
2557
- const content = "_content_1d8l2_31";
2560
+ const callout = "_callout_ov76x_1";
2561
+ const header = "_header_ov76x_26";
2562
+ const content = "_content_ov76x_32";
2558
2563
  const styles$b = {
2559
2564
  callout,
2560
2565
  header,
@@ -2582,11 +2587,12 @@ const COLOR_MAP = Object.freeze({
2582
2587
  icon: mdiAlertOctagram
2583
2588
  }
2584
2589
  });
2585
- const ElmCallout = component$(({ type = "note" }) => {
2590
+ const ElmCallout = component$(({ type = "note", style }) => {
2586
2591
  return /* @__PURE__ */ jsxs("aside", {
2587
2592
  class: styles$b.callout,
2588
2593
  style: {
2589
- "--callout-color": COLOR_MAP[type].code
2594
+ "--callout-color": COLOR_MAP[type].code,
2595
+ ...style
2590
2596
  },
2591
2597
  children: [
2592
2598
  /* @__PURE__ */ jsxs("div", {
@@ -2609,16 +2615,14 @@ const ElmCallout = component$(({ type = "note" }) => {
2609
2615
  ]
2610
2616
  });
2611
2617
  });
2612
- const hr = "_hr_1g58p_1";
2618
+ const hr = "_hr_b790w_1";
2613
2619
  const styles$a = {
2614
2620
  hr
2615
2621
  };
2616
- const ElmDivider = component$(({ margin }) => {
2622
+ const ElmDivider = component$(({ style }) => {
2617
2623
  return /* @__PURE__ */ jsx("hr", {
2618
2624
  class: styles$a.hr,
2619
- style: {
2620
- marginBlock: margin
2621
- }
2625
+ style
2622
2626
  });
2623
2627
  });
2624
2628
  const fragment = "_fragment_1kofp_1";
@@ -2643,15 +2647,15 @@ const ElmFragmentIdentifier = component$(({ id }) => {
2643
2647
  children: "#"
2644
2648
  });
2645
2649
  });
2646
- const h1 = "_h1_16jof_10";
2647
- const h2 = "_h2_16jof_40";
2648
- const h2__underline = "_h2__underline_16jof_68";
2649
- const h3 = "_h3_16jof_85";
2650
- const h4 = "_h4_16jof_102";
2651
- const h5 = "_h5_16jof_106";
2652
- const h6 = "_h6_16jof_110";
2650
+ const h1 = "_h1_1c1xr_10";
2651
+ const h2 = "_h2_1c1xr_40";
2652
+ const h2__underline = "_h2__underline_1c1xr_68";
2653
+ const h3 = "_h3_1c1xr_85";
2654
+ const h4 = "_h4_1c1xr_102";
2655
+ const h5 = "_h5_1c1xr_106";
2656
+ const h6 = "_h6_1c1xr_110";
2653
2657
  const styles$8 = {
2654
- "heading-common": "_heading-common_16jof_1",
2658
+ "heading-common": "_heading-common_1c1xr_1",
2655
2659
  h1,
2656
2660
  h2,
2657
2661
  h2__underline,
@@ -2668,7 +2672,7 @@ const SIZE_MAP = Object.freeze({
2668
2672
  5: 1.15,
2669
2673
  6: 1.1
2670
2674
  });
2671
- const ElmHeading = component$(({ level, text: text2, id }) => {
2675
+ const ElmHeading = component$(({ level, text: text2, id, style }) => {
2672
2676
  const Tag = `h${level}`;
2673
2677
  return /* @__PURE__ */ jsxs(Tag, {
2674
2678
  class: [
@@ -2677,7 +2681,8 @@ const ElmHeading = component$(({ level, text: text2, id }) => {
2677
2681
  styles$8[`h${level}`]
2678
2682
  ],
2679
2683
  style: {
2680
- "--font-size": `${SIZE_MAP[level]}em`
2684
+ "--font-size": `${SIZE_MAP[level]}em`,
2685
+ ...style
2681
2686
  },
2682
2687
  children: [
2683
2688
  /* @__PURE__ */ jsx("span", {
@@ -2700,11 +2705,11 @@ const ElmHeading = component$(({ level, text: text2, id }) => {
2700
2705
  });
2701
2706
  });
2702
2707
  const styles$7 = {
2703
- "elmethis-list-common": "_elmethis-list-common_14epx_1",
2704
- "elmethis-bulleted-list": "_elmethis-bulleted-list_14epx_9",
2705
- "elmethis-numbered-list": "_elmethis-numbered-list_14epx_24"
2708
+ "elmethis-list-common": "_elmethis-list-common_6g6c5_1",
2709
+ "elmethis-bulleted-list": "_elmethis-bulleted-list_6g6c5_9",
2710
+ "elmethis-numbered-list": "_elmethis-numbered-list_6g6c5_24"
2706
2711
  };
2707
- const ElmList = component$(({ listStyle = "unordered" }) => {
2712
+ const ElmList = component$(({ listStyle = "unordered", style }) => {
2708
2713
  if (listStyle === "ordered") {
2709
2714
  return /* @__PURE__ */ jsx("ol", {
2710
2715
  class: [
@@ -2712,6 +2717,7 @@ const ElmList = component$(({ listStyle = "unordered" }) => {
2712
2717
  styles$7["elmethis-list-common"],
2713
2718
  styles$7["elmethis-numbered-list"]
2714
2719
  ],
2720
+ style,
2715
2721
  children: /* @__PURE__ */ jsx(Slot, {})
2716
2722
  });
2717
2723
  } else {
@@ -2725,7 +2731,7 @@ const ElmList = component$(({ listStyle = "unordered" }) => {
2725
2731
  });
2726
2732
  }
2727
2733
  });
2728
- const paragraph = "_paragraph_jz10s_1";
2734
+ const paragraph = "_paragraph_1klqe_1";
2729
2735
  const styles$6 = {
2730
2736
  paragraph
2731
2737
  };
@@ -2775,7 +2781,7 @@ const styles$5 = {
2775
2781
  };
2776
2782
  const HasRowHeaderContext = createContextId("HasRowHeaderContext");
2777
2783
  const ElmTable = component$((props) => {
2778
- const { margin, caption: caption2, hasRowHeader = false } = props;
2784
+ const { caption: caption2, hasRowHeader = false, style } = props;
2779
2785
  const hasRowHeaderComputed = useComputed$(() => hasRowHeader);
2780
2786
  useContextProvider(HasRowHeaderContext, hasRowHeaderComputed);
2781
2787
  return /* @__PURE__ */ jsxs("table", {
@@ -2784,7 +2790,7 @@ const ElmTable = component$((props) => {
2784
2790
  textStyles.text
2785
2791
  ],
2786
2792
  style: {
2787
- "--margin-block": margin
2793
+ ...style
2788
2794
  },
2789
2795
  children: [
2790
2796
  caption2 && /* @__PURE__ */ jsx("caption", {
@@ -2882,10 +2888,9 @@ const ElmTableCell = component$((props) => {
2882
2888
  })
2883
2889
  });
2884
2890
  });
2885
- const column = "_column_1l2bp_7";
2891
+ const column = "_column_1yujg_1";
2886
2892
  const styles$1 = {
2887
- "jarkup-body": "_jarkup-body_1l2bp_1",
2888
- "column-list": "_column-list_1l2bp_7",
2893
+ "column-list": "_column-list_1yujg_1",
2889
2894
  column
2890
2895
  };
2891
2896
  const convertInlineComponentsToPlainText = (inlineComponents) => {
@@ -3051,7 +3056,10 @@ const ElmJarkup = component$((props) => {
3051
3056
  });
3052
3057
  };
3053
3058
  return /* @__PURE__ */ jsx("div", {
3054
- class: styles$1["jarkup-body"],
3059
+ style: {
3060
+ "--margin-block": "3rem",
3061
+ ...props.style
3062
+ },
3055
3063
  children: render(props.jsonComponents)
3056
3064
  });
3057
3065
  });