@apia/theme 3.0.12 → 4.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -6,7 +6,7 @@ import { jsx, Fragment } from 'theme-ui/jsx-runtime';
6
6
  import { ThemeUIProvider, useThemeUI, Box, ThemeProvider } from 'theme-ui';
7
7
  import { useState, useRef, useMemo, Suspense } from 'react';
8
8
  import { useMount, setValueByPath, EventEmitter } from '@apia/util';
9
- import { spacing as spacing$1 } from '@apia/theme';
9
+ import { spacing as spacing$1, responsive as responsive$2 } from '@apia/theme';
10
10
 
11
11
  function defaultLighten(color, ratio) {
12
12
  return tinycolor(color).lighten(ratio ?? 20).toRgbString();
@@ -2798,6 +2798,102 @@ const buttonsBar = {
2798
2798
  };
2799
2799
  var buttonsBar$1 = buttonsBar;
2800
2800
 
2801
+ const apiaFinder = {
2802
+ additionalFiltersModal: {
2803
+ resize: "none",
2804
+ ".modal__main": {
2805
+ resize: "none"
2806
+ },
2807
+ ".modal__content": {
2808
+ overflow: "hidden",
2809
+ "&.modal__content": {
2810
+ flexDirection: "column",
2811
+ gap: spacing$1(4),
2812
+ ".additionalFilters__navbar": {
2813
+ display: "flex",
2814
+ justifyContent: "end",
2815
+ gap: spacing$1(4)
2816
+ }
2817
+ }
2818
+ },
2819
+ ".additionalFiltersContent": {
2820
+ width: "100%",
2821
+ minWidth: "min(600px, 75vw)",
2822
+ maxWidth: "600px",
2823
+ overflow: "hidden",
2824
+ display: "flex",
2825
+ flexDirection: "column",
2826
+ maxHeight: "100%",
2827
+ gap: spacing$1(3),
2828
+ ".accordionElement, .accordion__item": {
2829
+ maxHeight: "100%",
2830
+ overflow: "hidden",
2831
+ display: "flex",
2832
+ flexDirection: "column",
2833
+ flexGrow: 100,
2834
+ mb: spacing$1(0),
2835
+ ".content, .accordion__item__content": {
2836
+ overflow: "auto",
2837
+ "&>div": {
2838
+ border: "1px solid",
2839
+ borderColor: "palette.border.article",
2840
+ p: spacing$1(5),
2841
+ "& label": {
2842
+ flexDirection: "column",
2843
+ justifyContent: "stretch",
2844
+ textAlign: "left",
2845
+ alignItems: "stretch",
2846
+ span: {
2847
+ mb: spacing$1(1)
2848
+ }
2849
+ }
2850
+ }
2851
+ }
2852
+ },
2853
+ "#FilterTypes_content": {
2854
+ "& label": {
2855
+ mb: spacing$1(4)
2856
+ },
2857
+ ".confirmRow": {
2858
+ textAlign: "right"
2859
+ }
2860
+ }
2861
+ }
2862
+ },
2863
+ ".modal__main": {
2864
+ maxHeight: responsive$2({ 0: "100vh", 5: "85vh", 6: "75vh" }),
2865
+ maxWidth: "max-content",
2866
+ '&[style*="width"]': {
2867
+ maxWidth: "unset"
2868
+ },
2869
+ ".confirm__content": {
2870
+ justifyContent: "space-between",
2871
+ maxHeight: "100%",
2872
+ overflow: "hidden",
2873
+ width: "100%",
2874
+ display: "flex",
2875
+ flexDirection: "column",
2876
+ ".finder__content": {
2877
+ maxWidth: "100%",
2878
+ flexGrow: 100,
2879
+ border: "1px solid",
2880
+ borderColor: "palette.border.section",
2881
+ overflow: "auto",
2882
+ ".selection__keyHandler": {
2883
+ width: "100%"
2884
+ }
2885
+ },
2886
+ ".finder__statistics": {
2887
+ flexShrink: 0
2888
+ }
2889
+ }
2890
+ },
2891
+ ".results": {
2892
+ mt: "7px"
2893
+ }
2894
+ };
2895
+ var apiaFinder$1 = apiaFinder;
2896
+
2801
2897
  const modals = {
2802
2898
  apiaApi,
2803
2899
  buttonsBar: buttonsBar$1,
@@ -2805,6 +2901,7 @@ const modals = {
2805
2901
  ...overlay,
2806
2902
  table: table$1,
2807
2903
  tableModal: tableModal$1,
2904
+ apiaFinder: apiaFinder$1,
2808
2905
  main: {
2809
2906
  boxShadow: "modals",
2810
2907
  borderRadius: "modals",
@@ -4499,6 +4596,76 @@ const datePicker = {
4499
4596
  maxWidth: "400px"
4500
4597
  };
4501
4598
 
4599
+ const aiMessage = {
4600
+ position: "relative",
4601
+ ".closeButton": {
4602
+ borderRadius: "5px",
4603
+ right: "0px",
4604
+ top: "-2px",
4605
+ zIndex: "15",
4606
+ position: "absolute",
4607
+ variant: "buttons.icon-outline-danger"
4608
+ },
4609
+ ".descriptionButton": {
4610
+ borderRadius: "5px",
4611
+ right: "28px",
4612
+ top: "-2px",
4613
+ zIndex: "15",
4614
+ position: "absolute",
4615
+ variant: "buttons.icon-outline"
4616
+ },
4617
+ genericBox: {
4618
+ margin: "10px",
4619
+ display: "flex",
4620
+ flexDirection: "column",
4621
+ justifyContent: "space-between",
4622
+ alignItems: "center",
4623
+ padding: "12px"
4624
+ },
4625
+ fileBox: {
4626
+ variant: "layout.common.components.aiMessage.genericBox",
4627
+ width: "130px",
4628
+ height: "120px",
4629
+ backgroundColor: "#f0f0f0",
4630
+ border: "1px solid #ccc",
4631
+ borderRadius: "4px",
4632
+ position: "relative",
4633
+ display: "flex",
4634
+ img: {
4635
+ objectFit: "contain",
4636
+ width: "110px",
4637
+ height: "69px"
4638
+ }
4639
+ },
4640
+ fileName: {
4641
+ bottom: "4px",
4642
+ right: "4px",
4643
+ fontSize: "12px",
4644
+ color: "#333",
4645
+ textOverflow: "ellipsis",
4646
+ whiteSpace: "nowrap",
4647
+ overflow: "hidden",
4648
+ width: "inherit",
4649
+ textAlign: "center",
4650
+ px: "5px"
4651
+ },
4652
+ textBox: {
4653
+ variant: "layout.common.components.aiMessage.genericBox",
4654
+ width: "50px",
4655
+ padding: "10px",
4656
+ backgroundColor: "#fff",
4657
+ border: "1px solid #ddd",
4658
+ borderRadius: "4px",
4659
+ position: "relative"
4660
+ },
4661
+ textSnippet: {
4662
+ bottom: "4px",
4663
+ right: "4px",
4664
+ fontSize: "12px",
4665
+ color: "#555"
4666
+ }
4667
+ };
4668
+
4502
4669
  const components = {
4503
4670
  /* PREPEND HERE */
4504
4671
  accordion,
@@ -4506,7 +4673,8 @@ const components = {
4506
4673
  datePicker,
4507
4674
  pagination: pagination$1,
4508
4675
  chat,
4509
- toolbar
4676
+ toolbar,
4677
+ aiMessage
4510
4678
  };
4511
4679
 
4512
4680
  const labelBox = {
@@ -5308,7 +5476,7 @@ async function getRemarkable(extensions) {
5308
5476
 
5309
5477
  const parseMarkdown = async (options) => {
5310
5478
  const markdownLibrary = await getRemarkable(options.extensions);
5311
- const css = (await import('./styles-CmQhZbPb.js')).markdownParserStyles ?? new ErrorImporting();
5479
+ const css = (await import('./styles-BaY8MoR4.js')).markdownParserStyles ?? new ErrorImporting();
5312
5480
  if (css instanceof ErrorImporting)
5313
5481
  throw new Error("Could not import css, cannot continue");
5314
5482
  const html = options.htmlTemplate ?? (await import('./html-B-K0BIiw.js')).markdownHtml ?? new ErrorImporting();
@@ -5766,4 +5934,4 @@ class MarkdownBuilder {
5766
5934
  }
5767
5935
 
5768
5936
  export { ApiaThemeProvider as A, MarkdownBlock as M, getColorStates as a, getColorsAndStatesByDefinition as b, getColorsAndStatesByPath as c, getColorsByDefinition as d, getColorsByPath as e, getOneColorState as f, getColorState as g, applyStatesGetColor as h, makeStyledComponent as i, injectStyles as j, getSpacingLayouts as k, spacing as l, markdownExtensions as m, smallButton as n, focusOutline as o, parsePalette as p, getVariant as q, responsive$1 as r, spacingLayouts as s, MarkdownBuilder as t, useMainTheme as u, parseMarkdown as v, MarkdownList as w, MarkdownParagraph as x, MarkdownTable as y, MarkdownTableOfContents as z };
5769
- //# sourceMappingURL=index-B8vI1LSQ.js.map
5937
+ //# sourceMappingURL=index-CcjXuxbb.js.map