@foldkit/devtools 0.112.5 → 0.113.1

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.
@@ -1 +1 @@
1
- {"version":3,"file":"overlay.d.ts","sourceRoot":"","sources":["../src/overlay.ts"],"names":[],"mappings":"AACA,OAAO,EAEL,OAAO,EACP,MAAM,EAGN,OAAO,EAGP,MAAM,EAKN,MAAM,IAAI,CAAC,EAGX,eAAe,EAEhB,MAAM,QAAQ,CAAA;AACf,OAAO,KAAK,OAAO,MAAM,iBAAiB,CAAA;AAC1C,OAAO,EACL,KAAK,aAAa,EAElB,KAAK,aAAa,EAGlB,KAAK,WAAW,EAChB,KAAK,UAAU,EAKhB,MAAM,uBAAuB,CAAA;AAW9B,OAAO,KAAK,EAAE,YAAY,EAAE,gBAAgB,EAAE,MAAM,iBAAiB,CAAA;;oFA2D/B,CAAC;;;;;;;;;;;;;;;;;AAmPvC,cAAM,YAAa,SAAQ,iBAE1B;CAAG;;AAEJ,cAAM,iBAAkB,SAAQ,sBAGC;CAAG;AAEpC,eAAO,MAAM,UAAU;;iBAGsB,CAAA;AAE7C,eAAO,MAAM,YAAY;;iBAGwB,CAAA;AAWjD,eAAO,MAAM,MAAM;;;;wBAUlB,CAAA;AAED,eAAO,MAAM,YAAY;;;;;;;;wBAIqB,CAAA;AAE9C,eAAO,MAAM,aAAa;;;;;;wBASzB,CAAA;AAED,eAAO,MAAM,MAAM;;wBASlB,CAAA;AAED,eAAO,MAAM,KAAK;;wBASjB,CAAA;AAED,eAAO,MAAM,WAAW;;6BAYvB,CAAA;AA+rDD,eAAO,MAAM,aAAa,GACxB,OAAO,aAAa,EACpB,UAAU,gBAAgB,EAC1B,MAAM,YAAY,EAClB,aAAa,MAAM,CAAC,MAAM,CAAC,MAAM,CAAC,6DAuEhC,CAAA"}
1
+ {"version":3,"file":"overlay.d.ts","sourceRoot":"","sources":["../src/overlay.ts"],"names":[],"mappings":"AACA,OAAO,EAEL,OAAO,EACP,MAAM,EAGN,OAAO,EAGP,MAAM,EAKN,MAAM,IAAI,CAAC,EAGX,eAAe,EAEhB,MAAM,QAAQ,CAAA;AACf,OAAO,KAAK,OAAO,MAAM,iBAAiB,CAAA;AAC1C,OAAO,EACL,KAAK,aAAa,EAElB,KAAK,aAAa,EAGlB,KAAK,WAAW,EAChB,KAAK,UAAU,EAKhB,MAAM,uBAAuB,CAAA;AAW9B,OAAO,KAAK,EAAE,YAAY,EAAE,gBAAgB,EAAE,MAAM,iBAAiB,CAAA;;oFA2D/B,CAAC;;;;;;;;;;;;;;;;;AAmPvC,cAAM,YAAa,SAAQ,iBAE1B;CAAG;;AAEJ,cAAM,iBAAkB,SAAQ,sBAGC;CAAG;AAEpC,eAAO,MAAM,UAAU;;iBAGsB,CAAA;AAE7C,eAAO,MAAM,YAAY;;iBAGwB,CAAA;AAWjD,eAAO,MAAM,MAAM;;;;wBAUlB,CAAA;AAED,eAAO,MAAM,YAAY;;;;;;;;wBAIqB,CAAA;AAE9C,eAAO,MAAM,aAAa;;;;;;wBASzB,CAAA;AAED,eAAO,MAAM,MAAM;;wBASlB,CAAA;AAED,eAAO,MAAM,KAAK;;wBASjB,CAAA;AAED,eAAO,MAAM,WAAW;;6BAYvB,CAAA;AAwsDD,eAAO,MAAM,aAAa,GACxB,OAAO,aAAa,EACpB,UAAU,gBAAgB,EAC1B,MAAM,YAAY,EAClB,aAAa,MAAM,CAAC,MAAM,CAAC,MAAM,CAAC,6DAuEhC,CAAA"}
package/dist/overlay.js CHANGED
@@ -529,8 +529,8 @@ const makeView = (position, mode, shadow, maybeBanner) => {
529
529
  ], []),
530
530
  ]);
531
531
  const tagLabelView = (tag) => h.span([h.Key('tag'), h.Class('json-tag')], [tag]);
532
- const diffDotView = h.span([h.Key('diffdot'), h.Class('diff-dot')], []);
533
- const inlineDiffDotView = h.span([h.Class('diff-dot-inline')], []);
532
+ const diffDotView = () => h.span([h.Key('diffdot'), h.Class('diff-dot')], []);
533
+ const inlineDiffDotView = () => h.span([h.Class('diff-dot-inline')], []);
534
534
  const flattenTree = ({ value, treePath, depth, key, ...shared }) => {
535
535
  const { rootPath, expandedPaths, changedPaths, affectedPaths, accumulator, indentRootChildren, } = shared;
536
536
  const isRoot = treePath === rootPath;
@@ -583,7 +583,7 @@ const makeView = (position, mode, shadow, maybeBanner) => {
583
583
  })),
584
584
  indent,
585
585
  ], [
586
- ...(hasDiffDot ? [diffDotView] : []),
586
+ ...(hasDiffDot ? [diffDotView()] : []),
587
587
  ...(String_.isNonEmpty(key) ? [keyView(key)] : []),
588
588
  leafValueView(value),
589
589
  ]);
@@ -603,7 +603,7 @@ const makeView = (position, mode, shadow, maybeBanner) => {
603
603
  ...(isRoot ? [] : [h.OnClick(ToggledTreeNode({ path: treePath }))]),
604
604
  ], [
605
605
  ...(isRoot ? [] : [arrowView(isExpanded)]),
606
- ...(!isRoot && hasDiffDot ? [diffDotView] : []),
606
+ ...(!isRoot && hasDiffDot ? [diffDotView()] : []),
607
607
  ...(String_.isNonEmpty(key) ? [keyView(key)] : []),
608
608
  ...(String_.isNonEmpty(tag) ? [tagLabelView(tag)] : []),
609
609
  h.span([h.Key('value'), h.Class('json-preview')], [preview]),
@@ -657,7 +657,7 @@ const makeView = (position, mode, shadow, maybeBanner) => {
657
657
  : `+${remainingMs.toFixed(1)}ms`;
658
658
  }), Option.getOrElse(() => ''));
659
659
  };
660
- const emptyInspectorView = h.div([
660
+ const emptyInspectorView = () => h.div([
661
661
  h.Class('flex-1 flex items-center justify-center text-dt-muted text-2xs font-mono min-w-0'),
662
662
  ], ['Click a message to inspect']);
663
663
  const noMessageView = h.div([
@@ -860,7 +860,7 @@ const makeView = (position, mode, shadow, maybeBanner) => {
860
860
  : [h.Style({ display: 'none' })]),
861
861
  ], [
862
862
  Option.match(model.maybeInspectedModel, {
863
- onNone: () => emptyInspectorView,
863
+ onNone: () => emptyInspectorView(),
864
864
  onSome: inspectedModel => inspectorTabContent(model, tab.value, inspectedModel),
865
865
  }),
866
866
  ])),
@@ -901,7 +901,7 @@ const makeView = (position, mode, shadow, maybeBanner) => {
901
901
  const clearHistoryButton = h.button([h.Class(headerButtonClass), h.OnClick(ClickedClear())], ['Clear history']);
902
902
  const submodelLabel = (tag) => pipe(tag, String_.replace(/^Got/, ''), String_.replace(/Message$/, ''));
903
903
  const CHECK_ICON = 'M4.5 12.75l6 6 9-13.5';
904
- const checkIconView = h.svg([
904
+ const checkIconView = () => h.svg([
905
905
  h.AriaHidden(true),
906
906
  h.Class('dt-filter-check shrink-0'),
907
907
  h.Xmlns('http://www.w3.org/2000/svg'),
@@ -910,11 +910,15 @@ const makeView = (position, mode, shadow, maybeBanner) => {
910
910
  h.StrokeWidth('2'),
911
911
  h.Stroke('currentColor'),
912
912
  ], [
913
- h.path([h.D(CHECK_ICON), h.StrokeLinecap('round'), h.StrokeLinejoin('round')], []),
913
+ h.path([
914
+ h.D(CHECK_ICON),
915
+ h.StrokeLinecap('round'),
916
+ h.StrokeLinejoin('round'),
917
+ ], []),
914
918
  ]);
915
919
  const filterItemLabel = (item) => String_.isNonEmpty(item) ? submodelLabel(item) : 'All Messages';
916
920
  const ARROW_UP = 'M4.5 10.5L12 3m0 0l7.5 7.5M12 3v18';
917
- const arrowUpIconView = h.svg([
921
+ const arrowUpIconView = () => h.svg([
918
922
  h.AriaHidden(true),
919
923
  h.Class('dt-scroll-pill-icon shrink-0'),
920
924
  h.Xmlns('http://www.w3.org/2000/svg'),
@@ -930,7 +934,7 @@ const makeView = (position, mode, shadow, maybeBanner) => {
930
934
  h.Class('dt-scroll-pill'),
931
935
  h.OnClick(ClickedScrollToTopPill()),
932
936
  ], [
933
- arrowUpIconView,
937
+ arrowUpIconView(),
934
938
  h.span([h.Class('dt-scroll-pill-text')], ['Jump to top']),
935
939
  ]);
936
940
  const submodelFilterView = (model) => {
@@ -946,7 +950,7 @@ const makeView = (position, mode, shadow, maybeBanner) => {
946
950
  items: [ALL_MESSAGES_VALUE, ...model.submodelTags],
947
951
  itemToConfig: item => ({
948
952
  className: 'dt-filter-item',
949
- content: h.div([h.Class('flex items-center gap-2')], [checkIconView, h.span([], [filterItemLabel(item)])]),
953
+ content: h.div([h.Class('flex items-center gap-2')], [checkIconView(), h.span([], [filterItemLabel(item)])]),
950
954
  }),
951
955
  buttonContent: h.span([h.Class('flex flex-1 items-center justify-between')], [
952
956
  h.span([], [buttonLabel]),
@@ -1007,12 +1011,12 @@ const makeView = (position, mode, shadow, maybeBanner) => {
1007
1011
  h.Class(clsx(ROW_BASE, { selected: isSelected })),
1008
1012
  h.OnClick(ClickedRow({ index: INIT_INDEX })),
1009
1013
  ], [
1010
- ...OptionExt.when(mode === 'TimeTravel', h.span([h.Class('pause-column')], isPausedHere ? [pauseIconView] : [])).pipe(Option.toArray),
1014
+ ...OptionExt.when(mode === 'TimeTravel', h.span([h.Class('pause-column')], isPausedHere ? [pauseIconView()] : [])).pipe(Option.toArray),
1011
1015
  h.span([h.Class('dot-column')], []),
1012
1016
  h.span([h.Class(indexClass)], []),
1013
1017
  h.span([h.Class('text-base text-dt-muted font-mono')], ['init']),
1014
1018
  ]);
1015
- const pauseIconView = h.svg([
1019
+ const pauseIconView = () => h.svg([
1016
1020
  h.AriaHidden(true),
1017
1021
  h.Class('dt-pause-icon'),
1018
1022
  h.Xmlns('http://www.w3.org/2000/svg'),
@@ -1031,8 +1035,8 @@ const makeView = (position, mode, shadow, maybeBanner) => {
1031
1035
  h.Class(clsx(ROW_BASE, { selected: isSelected })),
1032
1036
  h.OnClick(ClickedRow({ index: absoluteIndex })),
1033
1037
  ], [
1034
- ...OptionExt.when(mode === 'TimeTravel', h.span([h.Class('pause-column')], isPausedHere ? [pauseIconView] : [])).pipe(Option.toArray),
1035
- h.span([h.Class('dot-column')], isModelChanged ? [inlineDiffDotView] : []),
1038
+ ...OptionExt.when(mode === 'TimeTravel', h.span([h.Class('pause-column')], isPausedHere ? [pauseIconView()] : [])).pipe(Option.toArray),
1039
+ h.span([h.Class('dot-column')], isModelChanged ? [inlineDiffDotView()] : []),
1036
1040
  h.span([h.Class(indexClass)], [String(absoluteIndex + 1)]),
1037
1041
  h.span([h.Class('text-base text-dt font-mono flex-1 truncate')], [tag]),
1038
1042
  h.span([
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@foldkit/devtools",
3
- "version": "0.112.5",
3
+ "version": "0.113.1",
4
4
  "description": "In-browser DevTools overlay for Foldkit applications",
5
5
  "type": "module",
6
6
  "main": "./dist/index.js",
@@ -17,21 +17,19 @@
17
17
  "dist"
18
18
  ],
19
19
  "peerDependencies": {
20
- "@effect/platform-browser": "4.0.0-beta.78",
21
20
  "@foldkit/ui": "^0",
22
- "effect": "4.0.0-beta.78",
21
+ "effect": "4.0.0-beta.83",
23
22
  "foldkit": "^0"
24
23
  },
25
24
  "dependencies": {
26
25
  "clsx": "^2.1.1"
27
26
  },
28
27
  "devDependencies": {
29
- "@effect/platform-browser": "4.0.0-beta.78",
30
- "effect": "4.0.0-beta.78",
28
+ "effect": "4.0.0-beta.83",
31
29
  "rimraf": "^6.1.3",
32
30
  "typescript": "^6.0.3",
33
- "@foldkit/ui": "0.112.5",
34
- "foldkit": "0.112.5"
31
+ "@foldkit/ui": "0.113.1",
32
+ "foldkit": "0.113.1"
35
33
  },
36
34
  "keywords": [
37
35
  "foldkit",