@iota-uz/sdk 0.45.0 → 0.47.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.
- package/README.md +5 -0
- package/dist/client-host/identity.d.ts +4 -4
- package/dist/client-host/identity.js +2 -2
- package/dist/lens/{CascadePanel-bXr7ekeZ.js → CascadePanel-BlYJd18G.js} +1 -1
- package/dist/lens/{ChartDataEquivalent-ZsncHfTF.js → ChartDataEquivalent-B6xSOdzC.js} +1 -1
- package/dist/lens/{ChartPanel-Cku9c87t.js → ChartPanel-BIJjrs5D.js} +159 -159
- package/dist/lens/{CoveragePanel-DE3fi5c7.js → CoveragePanel-CHtXDMtt.js} +1 -1
- package/dist/lens/{GaugePanel-DwR4zylR.js → GaugePanel-By0TOJPa.js} +1 -1
- package/dist/lens/LensDashboard.d.ts +13 -0
- package/dist/lens/LensDashboard.d.ts.map +1 -1
- package/dist/lens/{MapPanel-DJSiLZSz.js → MapPanel-Cw4ELCiM.js} +3 -3
- package/dist/lens/{MetricFlowPanel-Dsp_ntas.js → MetricFlowPanel-Gr5wi3nI.js} +2 -2
- package/dist/lens/{MetricHierarchyPanel-BYcy4FNw.js → MetricHierarchyPanel-VLA_5LXX.js} +2 -2
- package/dist/lens/{MetricRelationshipPanel-Gh5RKIu1.js → MetricRelationshipPanel-DFP566_c.js} +2 -2
- package/dist/lens/{PrintReport-RnKpLle9.js → PrintReport-C0OV1iHP.js} +5 -5
- package/dist/lens/{QualityChip-BxAn3wh6.js → QualityChip-DTi-0jdh.js} +1 -1
- package/dist/lens/SaveInvestigation-CX1Abyl8.js +309 -0
- package/dist/lens/TablePanel-BusKU7cU.js +994 -0
- package/dist/lens/{adapter-CZZIKpwb.js → adapter-CQg4-M7p.js} +7 -7
- package/dist/lens/contract/schemas.d.ts +2 -0
- package/dist/lens/contract/schemas.d.ts.map +1 -1
- package/dist/lens/contract/types.d.ts +14 -0
- package/dist/lens/contract/types.d.ts.map +1 -1
- package/dist/lens/{dashboardEdit-BLzL02OH.js → dashboardEdit-CJgCVfi_.js} +1 -1
- package/dist/lens/explore/DrillOverlay.d.ts +38 -0
- package/dist/lens/explore/DrillOverlay.d.ts.map +1 -1
- package/dist/lens/explore/ExplorePanel.d.ts.map +1 -1
- package/dist/lens/explore/SaveInvestigation.d.ts +21 -0
- package/dist/lens/explore/SaveInvestigation.d.ts.map +1 -0
- package/dist/lens/explore/drillHost.d.ts +25 -0
- package/dist/lens/explore/drillHost.d.ts.map +1 -0
- package/dist/lens/explore/investigation.d.ts +174 -0
- package/dist/lens/explore/investigation.d.ts.map +1 -0
- package/dist/lens/explore/provenanceLabels.d.ts +10 -0
- package/dist/lens/explore/provenanceLabels.d.ts.map +1 -0
- package/dist/lens/formula/FormulaTip.d.ts +5 -0
- package/dist/lens/formula/FormulaTip.d.ts.map +1 -1
- package/dist/lens/formula/FormulaView.d.ts.map +1 -1
- package/dist/lens/formula/PanelFormula.d.ts +2 -0
- package/dist/lens/formula/PanelFormula.d.ts.map +1 -1
- package/dist/lens/formula/element.d.ts.map +1 -1
- package/dist/lens/formula/values.d.ts +10 -1
- package/dist/lens/formula/values.d.ts.map +1 -1
- package/dist/lens/index-DR7Hf8Km.js +19805 -0
- package/dist/lens/{index-Dm3Y4NDq.js → index-DZFw4cqF.js} +1 -1
- package/dist/lens/index.d.ts +7 -1
- package/dist/lens/index.d.ts.map +1 -1
- package/dist/lens/index.js +67 -53
- package/dist/lens/{install-DCaRpfvv.js → install-B2lTK6uo.js} +1 -1
- package/dist/lens/{install-pvJpTP1f.js → install-BXr4Mnc0.js} +1 -1
- package/dist/lens/{install-C48hgC9S.js → install-CicNQ_ks.js} +1 -1
- package/dist/lens/{install-DB0eod1K.js → install-d8A0WPiw.js} +1 -1
- package/dist/lens/{keys-BAkGzg_y.js → keys-C-Akc9lZ.js} +2 -2
- package/dist/lens/panels/ChartPanel.d.ts.map +1 -1
- package/dist/lens/panels/TablePanel.d.ts.map +1 -1
- package/dist/lens/panels/actions.d.ts.map +1 -1
- package/dist/lens/panels/panelFailure.d.ts.map +1 -1
- package/dist/lens/{prefetch-j8VKR0tY.js → prefetch-C9kxuIs8.js} +2 -2
- package/dist/lens/{prefetchPanels-vwQqxrs4.js → prefetchPanels-gbY9RIqL.js} +1 -1
- package/dist/lens/{print-CuBcYmVF.js → print-CllsAP3d.js} +1 -1
- package/dist/lens/reports/ReportCompositionEditor.d.ts +8 -2
- package/dist/lens/reports/ReportCompositionEditor.d.ts.map +1 -1
- package/dist/lens/reports/ReportDefinitionEditor.d.ts +54 -0
- package/dist/lens/reports/ReportDefinitionEditor.d.ts.map +1 -0
- package/dist/lens/reports/ReportPicker.d.ts +6 -0
- package/dist/lens/reports/ReportPicker.d.ts.map +1 -1
- package/dist/lens/reports/dashboardEdit.d.ts +3 -0
- package/dist/lens/reports/dashboardEdit.d.ts.map +1 -1
- package/dist/lens/reports/editing.d.ts +35 -0
- package/dist/lens/reports/editing.d.ts.map +1 -1
- package/dist/lens/reports/picker.d.ts +4 -1
- package/dist/lens/reports/picker.d.ts.map +1 -1
- package/dist/lens/runtime/index.d.ts +0 -1
- package/dist/lens/runtime/index.d.ts.map +1 -1
- package/dist/lens/runtime/messages.d.ts +2 -2
- package/dist/lens/runtime/messages.d.ts.map +1 -1
- package/dist/lens/runtime/provider.d.ts +5 -1
- package/dist/lens/runtime/provider.d.ts.map +1 -1
- package/dist/lens/runtime/returnContext.d.ts +62 -0
- package/dist/lens/runtime/returnContext.d.ts.map +1 -0
- package/dist/lens/runtime/tableSummary.d.ts +9 -0
- package/dist/lens/runtime/tableSummary.d.ts.map +1 -0
- package/dist/lens/{scales-BSDq-uby.js → scales-CO6Q9RtG.js} +1 -1
- package/dist/lens/style.css +1 -1
- package/dist/runtime/README.md +24 -0
- package/dist/runtime/assert.d.ts +51 -0
- package/dist/runtime/assert.js +172 -0
- package/dist/runtime/build/README.txt +1 -0
- package/dist/runtime/build/extract.mjs +342 -0
- package/dist/runtime/build/shared-exports.json +388 -0
- package/dist/runtime/build/test-child.mjs +136 -0
- package/dist/runtime/build/theme/tailwind.config.js +121 -0
- package/dist/runtime/build/theme/theme.css +462 -0
- package/dist/runtime/build/theme/utilities.css +1 -0
- package/dist/runtime/build/vendor/lib/lib.d.ts +22 -0
- package/dist/runtime/build/vendor/lib/lib.decorators.d.ts +384 -0
- package/dist/runtime/build/vendor/lib/lib.decorators.legacy.d.ts +22 -0
- package/dist/runtime/build/vendor/lib/lib.dom.asynciterable.d.ts +41 -0
- package/dist/runtime/build/vendor/lib/lib.dom.d.ts +28983 -0
- package/dist/runtime/build/vendor/lib/lib.dom.iterable.d.ts +491 -0
- package/dist/runtime/build/vendor/lib/lib.es2015.collection.d.ts +147 -0
- package/dist/runtime/build/vendor/lib/lib.es2015.core.d.ts +597 -0
- package/dist/runtime/build/vendor/lib/lib.es2015.d.ts +28 -0
- package/dist/runtime/build/vendor/lib/lib.es2015.generator.d.ts +77 -0
- package/dist/runtime/build/vendor/lib/lib.es2015.iterable.d.ts +590 -0
- package/dist/runtime/build/vendor/lib/lib.es2015.promise.d.ts +81 -0
- package/dist/runtime/build/vendor/lib/lib.es2015.proxy.d.ts +128 -0
- package/dist/runtime/build/vendor/lib/lib.es2015.reflect.d.ts +144 -0
- package/dist/runtime/build/vendor/lib/lib.es2015.symbol.d.ts +46 -0
- package/dist/runtime/build/vendor/lib/lib.es2015.symbol.wellknown.d.ts +326 -0
- package/dist/runtime/build/vendor/lib/lib.es2016.array.include.d.ts +116 -0
- package/dist/runtime/build/vendor/lib/lib.es2016.d.ts +21 -0
- package/dist/runtime/build/vendor/lib/lib.es2016.full.d.ts +23 -0
- package/dist/runtime/build/vendor/lib/lib.es2016.intl.d.ts +31 -0
- package/dist/runtime/build/vendor/lib/lib.es2017.arraybuffer.d.ts +21 -0
- package/dist/runtime/build/vendor/lib/lib.es2017.d.ts +26 -0
- package/dist/runtime/build/vendor/lib/lib.es2017.date.d.ts +31 -0
- package/dist/runtime/build/vendor/lib/lib.es2017.full.d.ts +23 -0
- package/dist/runtime/build/vendor/lib/lib.es2017.intl.d.ts +44 -0
- package/dist/runtime/build/vendor/lib/lib.es2017.object.d.ts +49 -0
- package/dist/runtime/build/vendor/lib/lib.es2017.sharedmemory.d.ts +135 -0
- package/dist/runtime/build/vendor/lib/lib.es2017.string.d.ts +45 -0
- package/dist/runtime/build/vendor/lib/lib.es2017.typedarrays.d.ts +53 -0
- package/dist/runtime/build/vendor/lib/lib.es2018.asyncgenerator.d.ts +77 -0
- package/dist/runtime/build/vendor/lib/lib.es2018.asynciterable.d.ts +53 -0
- package/dist/runtime/build/vendor/lib/lib.es2018.d.ts +24 -0
- package/dist/runtime/build/vendor/lib/lib.es2018.full.d.ts +24 -0
- package/dist/runtime/build/vendor/lib/lib.es2018.intl.d.ts +83 -0
- package/dist/runtime/build/vendor/lib/lib.es2018.promise.d.ts +30 -0
- package/dist/runtime/build/vendor/lib/lib.es2018.regexp.d.ts +37 -0
- package/dist/runtime/build/vendor/lib/lib.es2019.array.d.ts +79 -0
- package/dist/runtime/build/vendor/lib/lib.es2019.d.ts +24 -0
- package/dist/runtime/build/vendor/lib/lib.es2019.full.d.ts +24 -0
- package/dist/runtime/build/vendor/lib/lib.es2019.intl.d.ts +23 -0
- package/dist/runtime/build/vendor/lib/lib.es2019.object.d.ts +33 -0
- package/dist/runtime/build/vendor/lib/lib.es2019.string.d.ts +37 -0
- package/dist/runtime/build/vendor/lib/lib.es2019.symbol.d.ts +24 -0
- package/dist/runtime/build/vendor/lib/lib.es2020.bigint.d.ts +731 -0
- package/dist/runtime/build/vendor/lib/lib.es2020.d.ts +27 -0
- package/dist/runtime/build/vendor/lib/lib.es2020.date.d.ts +42 -0
- package/dist/runtime/build/vendor/lib/lib.es2020.full.d.ts +24 -0
- package/dist/runtime/build/vendor/lib/lib.es2020.intl.d.ts +474 -0
- package/dist/runtime/build/vendor/lib/lib.es2020.number.d.ts +28 -0
- package/dist/runtime/build/vendor/lib/lib.es2020.promise.d.ts +47 -0
- package/dist/runtime/build/vendor/lib/lib.es2020.sharedmemory.d.ts +99 -0
- package/dist/runtime/build/vendor/lib/lib.es2020.string.d.ts +44 -0
- package/dist/runtime/build/vendor/lib/lib.es2020.symbol.wellknown.d.ts +41 -0
- package/dist/runtime/build/vendor/lib/lib.es2021.d.ts +23 -0
- package/dist/runtime/build/vendor/lib/lib.es2021.full.d.ts +24 -0
- package/dist/runtime/build/vendor/lib/lib.es2021.intl.d.ts +166 -0
- package/dist/runtime/build/vendor/lib/lib.es2021.promise.d.ts +48 -0
- package/dist/runtime/build/vendor/lib/lib.es2021.string.d.ts +33 -0
- package/dist/runtime/build/vendor/lib/lib.es2021.weakref.d.ts +78 -0
- package/dist/runtime/build/vendor/lib/lib.es2022.array.d.ts +121 -0
- package/dist/runtime/build/vendor/lib/lib.es2022.d.ts +25 -0
- package/dist/runtime/build/vendor/lib/lib.es2022.error.d.ts +75 -0
- package/dist/runtime/build/vendor/lib/lib.es2022.full.d.ts +24 -0
- package/dist/runtime/build/vendor/lib/lib.es2022.intl.d.ts +121 -0
- package/dist/runtime/build/vendor/lib/lib.es2022.object.d.ts +26 -0
- package/dist/runtime/build/vendor/lib/lib.es2022.regexp.d.ts +39 -0
- package/dist/runtime/build/vendor/lib/lib.es2022.string.d.ts +25 -0
- package/dist/runtime/build/vendor/lib/lib.es2023.array.d.ts +924 -0
- package/dist/runtime/build/vendor/lib/lib.es2023.collection.d.ts +21 -0
- package/dist/runtime/build/vendor/lib/lib.es2023.d.ts +22 -0
- package/dist/runtime/build/vendor/lib/lib.es2023.full.d.ts +24 -0
- package/dist/runtime/build/vendor/lib/lib.es2023.intl.d.ts +56 -0
- package/dist/runtime/build/vendor/lib/lib.es2024.arraybuffer.d.ts +65 -0
- package/dist/runtime/build/vendor/lib/lib.es2024.collection.d.ts +29 -0
- package/dist/runtime/build/vendor/lib/lib.es2024.d.ts +26 -0
- package/dist/runtime/build/vendor/lib/lib.es2024.full.d.ts +24 -0
- package/dist/runtime/build/vendor/lib/lib.es2024.object.d.ts +29 -0
- package/dist/runtime/build/vendor/lib/lib.es2024.promise.d.ts +35 -0
- package/dist/runtime/build/vendor/lib/lib.es2024.regexp.d.ts +25 -0
- package/dist/runtime/build/vendor/lib/lib.es2024.sharedmemory.d.ts +68 -0
- package/dist/runtime/build/vendor/lib/lib.es2024.string.d.ts +29 -0
- package/dist/runtime/build/vendor/lib/lib.es5.d.ts +4585 -0
- package/dist/runtime/build/vendor/lib/lib.es6.d.ts +23 -0
- package/dist/runtime/build/vendor/lib/lib.esnext.array.d.ts +35 -0
- package/dist/runtime/build/vendor/lib/lib.esnext.collection.d.ts +96 -0
- package/dist/runtime/build/vendor/lib/lib.esnext.d.ts +25 -0
- package/dist/runtime/build/vendor/lib/lib.esnext.decorators.d.ts +28 -0
- package/dist/runtime/build/vendor/lib/lib.esnext.disposable.d.ts +193 -0
- package/dist/runtime/build/vendor/lib/lib.esnext.full.d.ts +24 -0
- package/dist/runtime/build/vendor/lib/lib.esnext.intl.d.ts +21 -0
- package/dist/runtime/build/vendor/lib/lib.esnext.iterator.d.ts +148 -0
- package/dist/runtime/build/vendor/node-types/assert/strict.d.ts +111 -0
- package/dist/runtime/build/vendor/node-types/assert.d.ts +1115 -0
- package/dist/runtime/build/vendor/node-types/async_hooks.d.ts +619 -0
- package/dist/runtime/build/vendor/node-types/buffer.buffer.d.ts +477 -0
- package/dist/runtime/build/vendor/node-types/buffer.d.ts +1941 -0
- package/dist/runtime/build/vendor/node-types/child_process.d.ts +1480 -0
- package/dist/runtime/build/vendor/node-types/cluster.d.ts +578 -0
- package/dist/runtime/build/vendor/node-types/compatibility/iterators.d.ts +21 -0
- package/dist/runtime/build/vendor/node-types/console.d.ts +453 -0
- package/dist/runtime/build/vendor/node-types/constants.d.ts +21 -0
- package/dist/runtime/build/vendor/node-types/crypto.d.ts +5484 -0
- package/dist/runtime/build/vendor/node-types/dgram.d.ts +715 -0
- package/dist/runtime/build/vendor/node-types/diagnostics_channel.d.ts +576 -0
- package/dist/runtime/build/vendor/node-types/dns/promises.d.ts +503 -0
- package/dist/runtime/build/vendor/node-types/dns.d.ts +923 -0
- package/dist/runtime/build/vendor/node-types/domain.d.ts +166 -0
- package/dist/runtime/build/vendor/node-types/events.d.ts +967 -0
- package/dist/runtime/build/vendor/node-types/fs/promises.d.ts +1354 -0
- package/dist/runtime/build/vendor/node-types/fs.d.ts +4777 -0
- package/dist/runtime/build/vendor/node-types/globals.d.ts +170 -0
- package/dist/runtime/build/vendor/node-types/globals.typedarray.d.ts +41 -0
- package/dist/runtime/build/vendor/node-types/http.d.ts +2246 -0
- package/dist/runtime/build/vendor/node-types/http2.d.ts +2882 -0
- package/dist/runtime/build/vendor/node-types/https.d.ts +585 -0
- package/dist/runtime/build/vendor/node-types/index.d.ts +101 -0
- package/dist/runtime/build/vendor/node-types/inspector.d.ts +323 -0
- package/dist/runtime/build/vendor/node-types/inspector.generated.d.ts +4406 -0
- package/dist/runtime/build/vendor/node-types/module.d.ts +844 -0
- package/dist/runtime/build/vendor/node-types/net.d.ts +1197 -0
- package/dist/runtime/build/vendor/node-types/os.d.ts +507 -0
- package/dist/runtime/build/vendor/node-types/package.json +140 -0
- package/dist/runtime/build/vendor/node-types/path.d.ts +200 -0
- package/dist/runtime/build/vendor/node-types/perf_hooks.d.ts +1054 -0
- package/dist/runtime/build/vendor/node-types/process.d.ts +2101 -0
- package/dist/runtime/build/vendor/node-types/punycode.d.ts +117 -0
- package/dist/runtime/build/vendor/node-types/querystring.d.ts +152 -0
- package/dist/runtime/build/vendor/node-types/readline/promises.d.ts +161 -0
- package/dist/runtime/build/vendor/node-types/readline.d.ts +600 -0
- package/dist/runtime/build/vendor/node-types/repl.d.ts +438 -0
- package/dist/runtime/build/vendor/node-types/sea.d.ts +162 -0
- package/dist/runtime/build/vendor/node-types/sqlite.d.ts +1182 -0
- package/dist/runtime/build/vendor/node-types/stream/consumers.d.ts +45 -0
- package/dist/runtime/build/vendor/node-types/stream/promises.d.ts +90 -0
- package/dist/runtime/build/vendor/node-types/stream/web.d.ts +596 -0
- package/dist/runtime/build/vendor/node-types/stream.d.ts +1707 -0
- package/dist/runtime/build/vendor/node-types/string_decoder.d.ts +67 -0
- package/dist/runtime/build/vendor/node-types/test.d.ts +2656 -0
- package/dist/runtime/build/vendor/node-types/timers/promises.d.ts +108 -0
- package/dist/runtime/build/vendor/node-types/timers.d.ts +285 -0
- package/dist/runtime/build/vendor/node-types/tls.d.ts +1314 -0
- package/dist/runtime/build/vendor/node-types/trace_events.d.ts +197 -0
- package/dist/runtime/build/vendor/node-types/ts5.6/buffer.buffer.d.ts +473 -0
- package/dist/runtime/build/vendor/node-types/ts5.6/compatibility/float16array.d.ts +71 -0
- package/dist/runtime/build/vendor/node-types/ts5.6/globals.typedarray.d.ts +36 -0
- package/dist/runtime/build/vendor/node-types/ts5.6/index.d.ts +103 -0
- package/dist/runtime/build/vendor/node-types/ts5.7/compatibility/float16array.d.ts +72 -0
- package/dist/runtime/build/vendor/node-types/ts5.7/index.d.ts +103 -0
- package/dist/runtime/build/vendor/node-types/tty.d.ts +209 -0
- package/dist/runtime/build/vendor/node-types/url.d.ts +1103 -0
- package/dist/runtime/build/vendor/node-types/util.d.ts +2379 -0
- package/dist/runtime/build/vendor/node-types/v8.d.ts +1010 -0
- package/dist/runtime/build/vendor/node-types/vm.d.ts +1160 -0
- package/dist/runtime/build/vendor/node-types/wasi.d.ts +202 -0
- package/dist/runtime/build/vendor/node-types/web-globals/abortcontroller.d.ts +34 -0
- package/dist/runtime/build/vendor/node-types/web-globals/crypto.d.ts +32 -0
- package/dist/runtime/build/vendor/node-types/web-globals/domexception.d.ts +68 -0
- package/dist/runtime/build/vendor/node-types/web-globals/events.d.ts +97 -0
- package/dist/runtime/build/vendor/node-types/web-globals/fetch.d.ts +62 -0
- package/dist/runtime/build/vendor/node-types/web-globals/navigator.d.ts +25 -0
- package/dist/runtime/build/vendor/node-types/web-globals/storage.d.ts +24 -0
- package/dist/runtime/build/vendor/node-types/web-globals/streams.d.ts +22 -0
- package/dist/runtime/build/vendor/node-types/worker_threads.d.ts +894 -0
- package/dist/runtime/build/vendor/node-types/zlib.d.ts +768 -0
- package/dist/runtime/build/vendor/node_modules/csstype/LICENSE +19 -0
- package/dist/runtime/build/vendor/node_modules/csstype/index.d.ts +22569 -0
- package/dist/runtime/build/vendor/node_modules/csstype/index.js.flow +6863 -0
- package/dist/runtime/build/vendor/node_modules/csstype/package.json +70 -0
- package/dist/runtime/build/vendor/node_modules/seroval/LICENSE +7 -0
- package/dist/runtime/build/vendor/node_modules/seroval/dist/cjs/development/index.cjs +4232 -0
- package/dist/runtime/build/vendor/node_modules/seroval/dist/cjs/production/index.cjs +3 -0
- package/dist/runtime/build/vendor/node_modules/seroval/dist/esm/development/index.mjs +4209 -0
- package/dist/runtime/build/vendor/node_modules/seroval/dist/esm/production/index.mjs +3 -0
- package/dist/runtime/build/vendor/node_modules/seroval/dist/types/core/Serializer.d.ts +28 -0
- package/dist/runtime/build/vendor/node_modules/seroval/dist/types/core/base-primitives.d.ts +28 -0
- package/dist/runtime/build/vendor/node_modules/seroval/dist/types/core/compat.d.ts +15 -0
- package/dist/runtime/build/vendor/node_modules/seroval/dist/types/core/constants.d.ts +105 -0
- package/dist/runtime/build/vendor/node_modules/seroval/dist/types/core/constructors.d.ts +50 -0
- package/dist/runtime/build/vendor/node_modules/seroval/dist/types/core/context/async-parser.d.ts +20 -0
- package/dist/runtime/build/vendor/node_modules/seroval/dist/types/core/context/deserializer.d.ts +52 -0
- package/dist/runtime/build/vendor/node_modules/seroval/dist/types/core/context/parser.d.ts +62 -0
- package/dist/runtime/build/vendor/node_modules/seroval/dist/types/core/context/serializer.d.ts +103 -0
- package/dist/runtime/build/vendor/node_modules/seroval/dist/types/core/context/sync-parser.d.ts +61 -0
- package/dist/runtime/build/vendor/node_modules/seroval/dist/types/core/cross/index.d.ts +24 -0
- package/dist/runtime/build/vendor/node_modules/seroval/dist/types/core/errors.d.ts +47 -0
- package/dist/runtime/build/vendor/node_modules/seroval/dist/types/core/function-string.d.ts +3 -0
- package/dist/runtime/build/vendor/node_modules/seroval/dist/types/core/keys.d.ts +4 -0
- package/dist/runtime/build/vendor/node_modules/seroval/dist/types/core/literals.d.ts +10 -0
- package/dist/runtime/build/vendor/node_modules/seroval/dist/types/core/node.d.ts +8 -0
- package/dist/runtime/build/vendor/node_modules/seroval/dist/types/core/opaque-reference.d.ts +9 -0
- package/dist/runtime/build/vendor/node_modules/seroval/dist/types/core/plugin.d.ts +52 -0
- package/dist/runtime/build/vendor/node_modules/seroval/dist/types/core/reference.d.ts +6 -0
- package/dist/runtime/build/vendor/node_modules/seroval/dist/types/core/sequence.d.ts +11 -0
- package/dist/runtime/build/vendor/node_modules/seroval/dist/types/core/special-reference.d.ts +16 -0
- package/dist/runtime/build/vendor/node_modules/seroval/dist/types/core/stream.d.ts +17 -0
- package/dist/runtime/build/vendor/node_modules/seroval/dist/types/core/string.d.ts +4 -0
- package/dist/runtime/build/vendor/node_modules/seroval/dist/types/core/symbols.d.ts +14 -0
- package/dist/runtime/build/vendor/node_modules/seroval/dist/types/core/tree/index.d.ts +21 -0
- package/dist/runtime/build/vendor/node_modules/seroval/dist/types/core/types.d.ts +233 -0
- package/dist/runtime/build/vendor/node_modules/seroval/dist/types/core/utils/error.d.ts +6 -0
- package/dist/runtime/build/vendor/node_modules/seroval/dist/types/core/utils/get-identifier.d.ts +2 -0
- package/dist/runtime/build/vendor/node_modules/seroval/dist/types/core/utils/get-object-flag.d.ts +3 -0
- package/dist/runtime/build/vendor/node_modules/seroval/dist/types/core/utils/is-valid-identifier.d.ts +2 -0
- package/dist/runtime/build/vendor/node_modules/seroval/dist/types/core/utils/promise-to-result.d.ts +2 -0
- package/dist/runtime/build/vendor/node_modules/seroval/dist/types/core/utils/typed-array.d.ts +6 -0
- package/dist/runtime/build/vendor/node_modules/seroval/dist/types/core/utils/valid-properties.d.ts +3 -0
- package/dist/runtime/build/vendor/node_modules/seroval/dist/types/index.d.ts +18 -0
- package/dist/runtime/build/vendor/node_modules/seroval/package.json +67 -0
- package/dist/runtime/build/vendor/node_modules/seroval/src/core/Serializer.ts +119 -0
- package/dist/runtime/build/vendor/node_modules/seroval/src/core/base-primitives.ts +537 -0
- package/dist/runtime/build/vendor/node_modules/seroval/src/core/compat.ts +23 -0
- package/dist/runtime/build/vendor/node_modules/seroval/src/core/constants.ts +202 -0
- package/dist/runtime/build/vendor/node_modules/seroval/src/core/constructors.ts +265 -0
- package/dist/runtime/build/vendor/node_modules/seroval/src/core/context/async-parser.ts +666 -0
- package/dist/runtime/build/vendor/node_modules/seroval/src/core/context/deserializer.ts +832 -0
- package/dist/runtime/build/vendor/node_modules/seroval/src/core/context/parser.ts +335 -0
- package/dist/runtime/build/vendor/node_modules/seroval/src/core/context/serializer.ts +1524 -0
- package/dist/runtime/build/vendor/node_modules/seroval/src/core/context/sync-parser.ts +943 -0
- package/dist/runtime/build/vendor/node_modules/seroval/src/core/cross/index.ts +190 -0
- package/dist/runtime/build/vendor/node_modules/seroval/src/core/errors.ts +196 -0
- package/dist/runtime/build/vendor/node_modules/seroval/src/core/function-string.ts +31 -0
- package/dist/runtime/build/vendor/node_modules/seroval/src/core/keys.ts +17 -0
- package/dist/runtime/build/vendor/node_modules/seroval/src/core/literals.ts +43 -0
- package/dist/runtime/build/vendor/node_modules/seroval/src/core/node.ts +40 -0
- package/dist/runtime/build/vendor/node_modules/seroval/src/core/opaque-reference.ts +9 -0
- package/dist/runtime/build/vendor/node_modules/seroval/src/core/plugin.ts +105 -0
- package/dist/runtime/build/vendor/node_modules/seroval/src/core/reference.ts +66 -0
- package/dist/runtime/build/vendor/node_modules/seroval/src/core/sequence.ts +59 -0
- package/dist/runtime/build/vendor/node_modules/seroval/src/core/special-reference.ts +42 -0
- package/dist/runtime/build/vendor/node_modules/seroval/src/core/stream.ts +71 -0
- package/dist/runtime/build/vendor/node_modules/seroval/src/core/string.ts +86 -0
- package/dist/runtime/build/vendor/node_modules/seroval/src/core/symbols.ts +20 -0
- package/dist/runtime/build/vendor/node_modules/seroval/src/core/tree/index.ts +134 -0
- package/dist/runtime/build/vendor/node_modules/seroval/src/core/types.ts +377 -0
- package/dist/runtime/build/vendor/node_modules/seroval/src/core/utils/error.ts +73 -0
- package/dist/runtime/build/vendor/node_modules/seroval/src/core/utils/get-identifier.ts +18 -0
- package/dist/runtime/build/vendor/node_modules/seroval/src/core/utils/get-object-flag.ts +14 -0
- package/dist/runtime/build/vendor/node_modules/seroval/src/core/utils/is-valid-identifier.ts +12 -0
- package/dist/runtime/build/vendor/node_modules/seroval/src/core/utils/promise-to-result.ts +9 -0
- package/dist/runtime/build/vendor/node_modules/seroval/src/core/utils/typed-array.ts +56 -0
- package/dist/runtime/build/vendor/node_modules/seroval/src/core/utils/valid-properties.ts +34 -0
- package/dist/runtime/build/vendor/node_modules/seroval/src/index.ts +36 -0
- package/dist/runtime/build/vendor/node_modules/seroval-plugins/LICENSE +7 -0
- package/dist/runtime/build/vendor/node_modules/seroval-plugins/dist/cjs/development/web.cjs +826 -0
- package/dist/runtime/build/vendor/node_modules/seroval-plugins/dist/cjs/production/web.cjs +1 -0
- package/dist/runtime/build/vendor/node_modules/seroval-plugins/dist/esm/development/web.mjs +803 -0
- package/dist/runtime/build/vendor/node_modules/seroval-plugins/dist/esm/production/web.mjs +1 -0
- package/dist/runtime/build/vendor/node_modules/seroval-plugins/dist/types/web/abort-signal.d.ts +3 -0
- package/dist/runtime/build/vendor/node_modules/seroval-plugins/dist/types/web/blob.d.ts +3 -0
- package/dist/runtime/build/vendor/node_modules/seroval-plugins/dist/types/web/custom-event.d.ts +3 -0
- package/dist/runtime/build/vendor/node_modules/seroval-plugins/dist/types/web/dom-exception.d.ts +3 -0
- package/dist/runtime/build/vendor/node_modules/seroval-plugins/dist/types/web/event.d.ts +3 -0
- package/dist/runtime/build/vendor/node_modules/seroval-plugins/dist/types/web/file.d.ts +3 -0
- package/dist/runtime/build/vendor/node_modules/seroval-plugins/dist/types/web/form-data.d.ts +3 -0
- package/dist/runtime/build/vendor/node_modules/seroval-plugins/dist/types/web/headers.d.ts +3 -0
- package/dist/runtime/build/vendor/node_modules/seroval-plugins/dist/types/web/image-data.d.ts +3 -0
- package/dist/runtime/build/vendor/node_modules/seroval-plugins/dist/types/web/index.d.ts +15 -0
- package/dist/runtime/build/vendor/node_modules/seroval-plugins/dist/types/web/readable-stream.d.ts +3 -0
- package/dist/runtime/build/vendor/node_modules/seroval-plugins/dist/types/web/request.d.ts +3 -0
- package/dist/runtime/build/vendor/node_modules/seroval-plugins/dist/types/web/response.d.ts +3 -0
- package/dist/runtime/build/vendor/node_modules/seroval-plugins/dist/types/web/url-search-params.d.ts +3 -0
- package/dist/runtime/build/vendor/node_modules/seroval-plugins/dist/types/web/url.d.ts +3 -0
- package/dist/runtime/build/vendor/node_modules/seroval-plugins/package.json +70 -0
- package/dist/runtime/build/vendor/node_modules/seroval-plugins/web/abort-signal.ts +131 -0
- package/dist/runtime/build/vendor/node_modules/seroval-plugins/web/blob.ts +41 -0
- package/dist/runtime/build/vendor/node_modules/seroval-plugins/web/custom-event.ts +66 -0
- package/dist/runtime/build/vendor/node_modules/seroval-plugins/web/dom-exception.ts +57 -0
- package/dist/runtime/build/vendor/node_modules/seroval-plugins/web/event.ts +62 -0
- package/dist/runtime/build/vendor/node_modules/seroval-plugins/web/file.ts +50 -0
- package/dist/runtime/build/vendor/node_modules/seroval-plugins/web/form-data.ts +105 -0
- package/dist/runtime/build/vendor/node_modules/seroval-plugins/web/headers.ts +49 -0
- package/dist/runtime/build/vendor/node_modules/seroval-plugins/web/image-data.ts +74 -0
- package/dist/runtime/build/vendor/node_modules/seroval-plugins/web/index.ts +14 -0
- package/dist/runtime/build/vendor/node_modules/seroval-plugins/web/readable-stream.ts +148 -0
- package/dist/runtime/build/vendor/node_modules/seroval-plugins/web/request.ts +82 -0
- package/dist/runtime/build/vendor/node_modules/seroval-plugins/web/response.ts +65 -0
- package/dist/runtime/build/vendor/node_modules/seroval-plugins/web/url-search-params.ts +40 -0
- package/dist/runtime/build/vendor/node_modules/seroval-plugins/web/url.ts +37 -0
- package/dist/runtime/build/vendor/node_modules/solid-js/dist/server.cjs +824 -0
- package/dist/runtime/build/vendor/node_modules/solid-js/dist/server.js +770 -0
- package/dist/runtime/build/vendor/node_modules/solid-js/dist/solid.cjs +1808 -0
- package/dist/runtime/build/vendor/node_modules/solid-js/dist/solid.js +1753 -0
- package/dist/runtime/build/vendor/node_modules/solid-js/jsx-runtime.d.ts +1 -0
- package/dist/runtime/build/vendor/node_modules/solid-js/package.json +243 -0
- package/dist/runtime/build/vendor/node_modules/solid-js/store/dist/server.cjs +133 -0
- package/dist/runtime/build/vendor/node_modules/solid-js/store/dist/server.js +121 -0
- package/dist/runtime/build/vendor/node_modules/solid-js/store/dist/store.cjs +463 -0
- package/dist/runtime/build/vendor/node_modules/solid-js/store/dist/store.js +454 -0
- package/dist/runtime/build/vendor/node_modules/solid-js/store/package.json +46 -0
- package/dist/runtime/build/vendor/node_modules/solid-js/store/types/index.d.ts +12 -0
- package/dist/runtime/build/vendor/node_modules/solid-js/store/types/modifiers.d.ts +6 -0
- package/dist/runtime/build/vendor/node_modules/solid-js/store/types/mutable.d.ts +5 -0
- package/dist/runtime/build/vendor/node_modules/solid-js/store/types/server.d.ts +17 -0
- package/dist/runtime/build/vendor/node_modules/solid-js/store/types/store.d.ts +108 -0
- package/dist/runtime/build/vendor/node_modules/solid-js/types/index.d.ts +23 -0
- package/dist/runtime/build/vendor/node_modules/solid-js/types/jsx.d.ts +4253 -0
- package/dist/runtime/build/vendor/node_modules/solid-js/types/reactive/array.d.ts +44 -0
- package/dist/runtime/build/vendor/node_modules/solid-js/types/reactive/observable.d.ts +36 -0
- package/dist/runtime/build/vendor/node_modules/solid-js/types/reactive/scheduler.d.ts +10 -0
- package/dist/runtime/build/vendor/node_modules/solid-js/types/reactive/signal.d.ts +581 -0
- package/dist/runtime/build/vendor/node_modules/solid-js/types/render/Suspense.d.ts +26 -0
- package/dist/runtime/build/vendor/node_modules/solid-js/types/render/component.d.ts +111 -0
- package/dist/runtime/build/vendor/node_modules/solid-js/types/render/flow.d.ts +118 -0
- package/dist/runtime/build/vendor/node_modules/solid-js/types/render/hydration.d.ts +24 -0
- package/dist/runtime/build/vendor/node_modules/solid-js/types/render/index.d.ts +4 -0
- package/dist/runtime/build/vendor/node_modules/solid-js/types/server/index.d.ts +3 -0
- package/dist/runtime/build/vendor/node_modules/solid-js/types/server/reactive.d.ts +98 -0
- package/dist/runtime/build/vendor/node_modules/solid-js/types/server/rendering.d.ts +160 -0
- package/dist/runtime/build/vendor/node_modules/solid-js/web/dist/server.cjs +900 -0
- package/dist/runtime/build/vendor/node_modules/solid-js/web/dist/server.js +786 -0
- package/dist/runtime/build/vendor/node_modules/solid-js/web/dist/web.cjs +884 -0
- package/dist/runtime/build/vendor/node_modules/solid-js/web/dist/web.js +772 -0
- package/dist/runtime/build/vendor/node_modules/solid-js/web/package.json +46 -0
- package/dist/runtime/build/vendor/node_modules/solid-js/web/storage/dist/storage.cjs +12 -0
- package/dist/runtime/build/vendor/node_modules/solid-js/web/storage/dist/storage.js +10 -0
- package/dist/runtime/build/vendor/node_modules/solid-js/web/storage/package.json +15 -0
- package/dist/runtime/build/vendor/node_modules/solid-js/web/storage/types/index.d.ts +2 -0
- package/dist/runtime/build/vendor/node_modules/solid-js/web/types/client.d.ts +93 -0
- package/dist/runtime/build/vendor/node_modules/solid-js/web/types/core.d.ts +2 -0
- package/dist/runtime/build/vendor/node_modules/solid-js/web/types/index.d.ts +50 -0
- package/dist/runtime/build/vendor/node_modules/solid-js/web/types/jsx.d.ts +1 -0
- package/dist/runtime/build/vendor/node_modules/solid-js/web/types/server-mock.d.ts +65 -0
- package/dist/runtime/build/vendor/node_modules/solid-js/web/types/server.d.ts +187 -0
- package/dist/runtime/build/worker.mjs +293415 -0
- package/dist/runtime/catalog/sdk-natives.json +655 -0
- package/dist/runtime/cli/iota-ext.mjs +1028 -0
- package/dist/runtime/client-host/entry.d.ts +10 -0
- package/dist/runtime/client-host/entry.js +124 -0
- package/dist/runtime/client-host/hooks.d.ts +43 -0
- package/dist/runtime/client-host/hooks.js +94 -0
- package/dist/runtime/client-host/index.d.ts +9 -0
- package/dist/runtime/client-host/index.js +9 -0
- package/dist/runtime/client-host/islands.d.ts +44 -0
- package/dist/runtime/client-host/islands.js +165 -0
- package/dist/runtime/client-host/kit.d.ts +10 -0
- package/dist/runtime/client-host/kit.js +37 -0
- package/dist/runtime/client-host/page.d.ts +53 -0
- package/dist/runtime/client-host/page.js +217 -0
- package/dist/runtime/client-host/params.d.ts +8 -0
- package/dist/runtime/client-host/params.js +36 -0
- package/dist/runtime/client-host/protocol.d.ts +78 -0
- package/dist/runtime/client-host/protocol.js +26 -0
- package/dist/runtime/client-host/shared.d.ts +12 -0
- package/dist/runtime/client-host/shared.js +49 -0
- package/dist/runtime/client-host/shell.d.ts +88 -0
- package/dist/runtime/client-host/shell.js +195 -0
- package/dist/runtime/client-host/slots.d.ts +54 -0
- package/dist/runtime/client-host/slots.js +90 -0
- package/dist/runtime/client-host/styles.d.ts +7 -0
- package/dist/runtime/client-host/styles.js +61 -0
- package/dist/runtime/client-host/transport.d.ts +45 -0
- package/dist/runtime/client-host/transport.js +115 -0
- package/dist/runtime/client.d.ts +226 -0
- package/dist/runtime/client.js +121 -0
- package/dist/runtime/contracts.d.ts +204 -0
- package/dist/runtime/contracts.js +195 -0
- package/dist/runtime/docs/authoring.md +1609 -0
- package/dist/runtime/docs/example/docs/en/admin/limits.md +10 -0
- package/dist/runtime/docs/example/docs/en/getting-started.md +13 -0
- package/dist/runtime/docs/example/docs/en/points.md +9 -0
- package/dist/runtime/docs/example/docs/ru/getting-started.md +12 -0
- package/dist/runtime/docs/example/package.json +27 -0
- package/dist/runtime/docs/example/src/ClientScreen.tsx +10 -0
- package/dist/runtime/docs/example/src/RedemptionScreen.tsx +7 -0
- package/dist/runtime/docs/example/src/RewardsScreen.module.css +13 -0
- package/dist/runtime/docs/example/src/RewardsScreen.tsx +51 -0
- package/dist/runtime/docs/example/src/client.tsx +40 -0
- package/dist/runtime/docs/example/src/contracts.ts +132 -0
- package/dist/runtime/docs/example/src/css-modules.d.ts +5 -0
- package/dist/runtime/docs/example/src/server.test.ts +156 -0
- package/dist/runtime/docs/example/src/server.ts +188 -0
- package/dist/runtime/docs/example/tsconfig.json +16 -0
- package/dist/runtime/entity.d.ts +237 -0
- package/dist/runtime/entity.js +201 -0
- package/dist/runtime/fakes.d.ts +80 -0
- package/dist/runtime/fakes.js +88 -0
- package/dist/runtime/fixtures.d.ts +34 -0
- package/dist/runtime/fixtures.js +60 -0
- package/dist/runtime/help.d.ts +22 -0
- package/dist/runtime/help.js +51 -0
- package/dist/runtime/host/context.mjs +392 -0
- package/dist/runtime/host/errors.mjs +64 -0
- package/dist/runtime/host/loader.mjs +28 -0
- package/dist/runtime/host/protocol.mjs +4 -0
- package/dist/runtime/host/register.mjs +8 -0
- package/dist/runtime/host/sdk/assert.mjs +153 -0
- package/dist/runtime/host/sdk/client-host/hooks.mjs +86 -0
- package/dist/runtime/host/sdk/client-host/protocol.mjs +30 -0
- package/dist/runtime/host/sdk/client-host/slots.mjs +82 -0
- package/dist/runtime/host/sdk/client-host/styles.mjs +45 -0
- package/dist/runtime/host/sdk/client-host/transport.mjs +102 -0
- package/dist/runtime/host/sdk/client.mjs +115 -0
- package/dist/runtime/host/sdk/contracts.mjs +185 -0
- package/dist/runtime/host/sdk/entity.mjs +183 -0
- package/dist/runtime/host/sdk/fakes.mjs +88 -0
- package/dist/runtime/host/sdk/fixtures.mjs +56 -0
- package/dist/runtime/host/sdk/help.mjs +37 -0
- package/dist/runtime/host/sdk/index.mjs +83 -0
- package/dist/runtime/host/sdk/kit.mjs +11 -0
- package/dist/runtime/host/sdk/manifest.mjs +276 -0
- package/dist/runtime/host/sdk/model.mjs +4 -0
- package/dist/runtime/host/sdk/resource.mjs +34 -0
- package/dist/runtime/host/sdk/schema.mjs +75 -0
- package/dist/runtime/host/sdk/server.mjs +43 -0
- package/dist/runtime/host/sdk/testhost.mjs +992 -0
- package/dist/runtime/host/sdk/testing.mjs +21 -0
- package/dist/runtime/host/sdk/wire.mjs +207 -0
- package/dist/runtime/host/worker.mjs +252 -0
- package/dist/runtime/index.d.ts +10 -0
- package/dist/runtime/index.js +5 -0
- package/dist/runtime/kit.d.ts +5 -0
- package/dist/runtime/kit.js +14 -0
- package/dist/runtime/manifest.d.ts +17 -0
- package/dist/runtime/manifest.js +323 -0
- package/dist/runtime/model.d.ts +224 -0
- package/dist/runtime/model.js +3 -0
- package/dist/runtime/resource.d.ts +31 -0
- package/dist/runtime/resource.js +35 -0
- package/dist/runtime/schema.d.ts +97 -0
- package/dist/runtime/schema.js +73 -0
- package/dist/runtime/server.d.ts +445 -0
- package/dist/runtime/server.js +41 -0
- package/dist/runtime/testhost.d.ts +216 -0
- package/dist/runtime/testhost.js +1146 -0
- package/dist/runtime/testing.d.ts +10 -0
- package/dist/runtime/testing.js +7 -0
- package/dist/runtime/wire.d.ts +26 -0
- package/dist/runtime/wire.js +236 -0
- package/dist/sdk-identity.cjs +3 -3
- package/dist/sdk-identity.js +3 -3
- package/dist/sdk-identity.json +2 -2
- package/dist/solid-ui/embedded-css.d.ts +2 -0
- package/dist/solid-ui/embedded-css.js +1 -0
- package/dist/solid-ui/embedded.css +2 -0
- package/dist/testing/components.d.ts +73 -0
- package/dist/testing/components.js +96 -0
- package/dist/testing/htmx.d.ts +44 -0
- package/dist/testing/htmx.js +284 -0
- package/dist/testing/index.d.ts +4 -41
- package/dist/testing/index.js +3 -206
- package/dist/testing/scenarios.d.ts +83 -0
- package/dist/testing/scenarios.js +74 -0
- package/dist/testing/wait.d.ts +7 -0
- package/dist/testing/wait.js +19 -0
- package/package.json +33 -2
- package/dist/lens/TablePanel-DU_ydQ1x.js +0 -980
- package/dist/lens/index-BJIuggdQ.js +0 -18403
- package/dist/lens/runtime/recovery.d.ts +0 -26
- package/dist/lens/runtime/recovery.d.ts.map +0 -1
package/dist/testing/index.js
CHANGED
|
@@ -1,192 +1,5 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
if (!Number.isInteger(value) || value <= 0)
|
|
4
|
-
throw new Error('timeoutMs must be a positive integer');
|
|
5
|
-
return value;
|
|
6
|
-
}
|
|
7
|
-
export async function actionAndResponse(page, match, action, options = {}) {
|
|
8
|
-
const response = page.waitForResponse(r => typeof match === 'function' ? match(r) : r.request().method() === match.method.toUpperCase() && new URL(r.url()).pathname === match.pathname, { timeout: timeout(options) });
|
|
9
|
-
const [result] = await Promise.all([response, action()]);
|
|
10
|
-
return result;
|
|
11
|
-
}
|
|
12
|
-
/** Installs the event observer before the action and follows replacement targets by selector. */
|
|
13
|
-
export async function actionAndHtmxSettled(page, target, action, options = {}) {
|
|
14
|
-
const key = `sdk-htmx-${crypto.randomUUID()}`;
|
|
15
|
-
await page.evaluate(({ key, target }) => {
|
|
16
|
-
const state = { pending: 0, swapped: false, settled: false, failed: false };
|
|
17
|
-
const requests = new WeakSet();
|
|
18
|
-
const matches = (event) => {
|
|
19
|
-
const detail = event.detail;
|
|
20
|
-
const element = detail?.target ?? detail?.elt;
|
|
21
|
-
return element instanceof Element && (element.matches(target) || Boolean(element.closest(target)));
|
|
22
|
-
};
|
|
23
|
-
const before = (event) => {
|
|
24
|
-
const detail = event.detail;
|
|
25
|
-
if (matches(event) && detail?.xhr && !requests.has(detail.xhr)) {
|
|
26
|
-
requests.add(detail.xhr);
|
|
27
|
-
state.pending++;
|
|
28
|
-
state.settled = false;
|
|
29
|
-
}
|
|
30
|
-
};
|
|
31
|
-
const correlated = (event) => { const xhr = event.detail?.xhr; return xhr && requests.has(xhr); };
|
|
32
|
-
const swap = (event) => { if (correlated(event))
|
|
33
|
-
state.swapped = true; };
|
|
34
|
-
const settle = (event) => { if (correlated(event) && state.swapped) {
|
|
35
|
-
requests.delete(event.detail.xhr);
|
|
36
|
-
state.pending--;
|
|
37
|
-
state.settled = state.pending === 0;
|
|
38
|
-
} };
|
|
39
|
-
const error = (event) => { if (correlated(event))
|
|
40
|
-
state.failed = true; };
|
|
41
|
-
document.addEventListener('htmx:beforeRequest', before);
|
|
42
|
-
document.addEventListener('htmx:afterSwap', swap);
|
|
43
|
-
document.addEventListener('htmx:afterSettle', settle);
|
|
44
|
-
document.addEventListener('htmx:responseError', error);
|
|
45
|
-
window[key] = { state, dispose: () => {
|
|
46
|
-
document.removeEventListener('htmx:beforeRequest', before);
|
|
47
|
-
document.removeEventListener('htmx:afterSwap', swap);
|
|
48
|
-
document.removeEventListener('htmx:afterSettle', settle);
|
|
49
|
-
document.removeEventListener('htmx:responseError', error);
|
|
50
|
-
} };
|
|
51
|
-
}, { key, target });
|
|
52
|
-
try {
|
|
53
|
-
await action();
|
|
54
|
-
await page.waitForFunction(key => window[key].state.settled || window[key].state.failed, key, { timeout: timeout(options) });
|
|
55
|
-
const failed = await page.evaluate(key => window[key].state.failed, key);
|
|
56
|
-
if (failed)
|
|
57
|
-
throw new Error(`HTMX response failed for ${target}`);
|
|
58
|
-
await page.locator(target).waitFor({ state: 'visible', timeout: timeout(options) });
|
|
59
|
-
}
|
|
60
|
-
finally {
|
|
61
|
-
await page.evaluate(key => { window[key]?.dispose(); delete window[key]; }, key);
|
|
62
|
-
}
|
|
63
|
-
}
|
|
64
|
-
export async function actionAndValidationRefusal(page, form, action) {
|
|
65
|
-
const key = `sdk-validation-${crypto.randomUUID()}`;
|
|
66
|
-
await form.evaluate((element, key) => {
|
|
67
|
-
const state = { invalid: null, submitted: false };
|
|
68
|
-
const invalid = (event) => {
|
|
69
|
-
const control = event.target;
|
|
70
|
-
state.invalid ??= { controlName: control.name, message: control.validationMessage };
|
|
71
|
-
};
|
|
72
|
-
const submit = () => { state.submitted = true; };
|
|
73
|
-
element.addEventListener('invalid', invalid, true);
|
|
74
|
-
element.addEventListener('submit', submit);
|
|
75
|
-
window[key] = { state, dispose: () => { element.removeEventListener('invalid', invalid, true); element.removeEventListener('submit', submit); } };
|
|
76
|
-
}, key);
|
|
77
|
-
const submission = await form.evaluate(element => {
|
|
78
|
-
const f = element;
|
|
79
|
-
return { url: new URL(f.getAttribute('hx-post') ?? f.action, location.href).href, method: f.hasAttribute('hx-post') ? 'POST' : f.method.toUpperCase() };
|
|
80
|
-
});
|
|
81
|
-
let submittedRequest = false;
|
|
82
|
-
const observe = (request) => {
|
|
83
|
-
if (request.url().split('?')[0] === submission.url.split('?')[0] && request.method() === submission.method)
|
|
84
|
-
submittedRequest = true;
|
|
85
|
-
};
|
|
86
|
-
page.on('request', observe);
|
|
87
|
-
try {
|
|
88
|
-
await action();
|
|
89
|
-
if (submittedRequest)
|
|
90
|
-
throw new Error('Native validation unexpectedly issued a submission request');
|
|
91
|
-
return await page.evaluate(key => {
|
|
92
|
-
const state = window[key].state;
|
|
93
|
-
if (!state.invalid || state.submitted)
|
|
94
|
-
throw new Error('Expected native validation refusal without submission');
|
|
95
|
-
return state.invalid;
|
|
96
|
-
}, key);
|
|
97
|
-
}
|
|
98
|
-
finally {
|
|
99
|
-
page.off('request', observe);
|
|
100
|
-
await page.evaluate(key => { window[key]?.dispose(); delete window[key]; }, key);
|
|
101
|
-
}
|
|
102
|
-
}
|
|
103
|
-
export async function expectComponentReady(page, root, options = {}) {
|
|
104
|
-
await waitForCondition(async () => await root.getAttribute(options.readinessAttribute ?? 'data-component-ready') === 'true', timeout(options), 'Component readiness marker missing');
|
|
105
|
-
await page.waitForFunction(() => document.fonts.status === 'loaded', undefined, { timeout: timeout(options) });
|
|
106
|
-
await root.waitFor({ state: 'visible', timeout: timeout(options) });
|
|
107
|
-
}
|
|
108
|
-
export async function openComponentCase(page, host, componentCase, options = {}) {
|
|
109
|
-
await page.setViewportSize(componentCase.viewport);
|
|
110
|
-
const root = await host.navigate(page, componentCase);
|
|
111
|
-
await expectComponentReady(page, root, options);
|
|
112
|
-
return root;
|
|
113
|
-
}
|
|
114
|
-
export async function actionAndHtmxResponse(page, match, action, options = {}) {
|
|
115
|
-
const key = `sdk-response-${crypto.randomUUID()}`;
|
|
116
|
-
await page.evaluate(key => {
|
|
117
|
-
const records = [];
|
|
118
|
-
const requests = new WeakMap();
|
|
119
|
-
const observed = new Set();
|
|
120
|
-
const before = (event) => {
|
|
121
|
-
const d = event.detail;
|
|
122
|
-
if (!d?.xhr)
|
|
123
|
-
return;
|
|
124
|
-
const record = { url: new URL(d.requestConfig.path, location.href).href, method: String(d.requestConfig.verb).toUpperCase(), status: 0, settled: false, failed: false, aborted: false };
|
|
125
|
-
records.push(record);
|
|
126
|
-
requests.set(d.xhr, record);
|
|
127
|
-
// A removed swap target no longer bubbles its lifecycle events to document.
|
|
128
|
-
for (const element of [d.elt, d.target]) {
|
|
129
|
-
if (!(element instanceof Element) || observed.has(element))
|
|
130
|
-
continue;
|
|
131
|
-
observed.add(element);
|
|
132
|
-
element.addEventListener('htmx:afterSettle', update);
|
|
133
|
-
element.addEventListener('htmx:responseError', update);
|
|
134
|
-
element.addEventListener('htmx:sendAbort', update);
|
|
135
|
-
element.addEventListener('htmx:sendError', update);
|
|
136
|
-
}
|
|
137
|
-
};
|
|
138
|
-
const update = (event) => {
|
|
139
|
-
const d = event.detail;
|
|
140
|
-
const record = d?.xhr && requests.get(d.xhr);
|
|
141
|
-
if (!record)
|
|
142
|
-
return;
|
|
143
|
-
record.url = d.xhr.responseURL || record.url;
|
|
144
|
-
record.status = d.xhr.status;
|
|
145
|
-
record.failed = event.type === 'htmx:responseError' || event.type === 'htmx:sendError';
|
|
146
|
-
record.aborted = event.type === 'htmx:sendAbort';
|
|
147
|
-
record.settled = event.type === 'htmx:afterSettle';
|
|
148
|
-
};
|
|
149
|
-
document.addEventListener('htmx:beforeRequest', before);
|
|
150
|
-
document.addEventListener('htmx:afterSettle', update);
|
|
151
|
-
document.addEventListener('htmx:responseError', update);
|
|
152
|
-
document.addEventListener('htmx:sendAbort', update);
|
|
153
|
-
document.addEventListener('htmx:sendError', update);
|
|
154
|
-
window[key] = { records, dispose: () => {
|
|
155
|
-
document.removeEventListener('htmx:beforeRequest', before);
|
|
156
|
-
document.removeEventListener('htmx:afterSettle', update);
|
|
157
|
-
document.removeEventListener('htmx:responseError', update);
|
|
158
|
-
document.removeEventListener('htmx:sendAbort', update);
|
|
159
|
-
document.removeEventListener('htmx:sendError', update);
|
|
160
|
-
for (const element of observed) {
|
|
161
|
-
element.removeEventListener('htmx:afterSettle', update);
|
|
162
|
-
element.removeEventListener('htmx:responseError', update);
|
|
163
|
-
element.removeEventListener('htmx:sendAbort', update);
|
|
164
|
-
element.removeEventListener('htmx:sendError', update);
|
|
165
|
-
}
|
|
166
|
-
} };
|
|
167
|
-
}, key);
|
|
168
|
-
try {
|
|
169
|
-
const response = await actionAndResponse(page, match, action, options);
|
|
170
|
-
const identity = { url: response.url(), method: response.request().method(), status: response.status() };
|
|
171
|
-
await page.waitForFunction(({ key, identity }) => {
|
|
172
|
-
const records = window[key].records.filter((r) => r.url === identity.url && r.method === identity.method);
|
|
173
|
-
return records.some((r) => !r.aborted && (r.settled || r.failed)) && records.every((r) => r.settled || r.failed || r.aborted);
|
|
174
|
-
}, { key, identity }, { timeout: timeout(options) });
|
|
175
|
-
const failure = await page.evaluate(({ key, identity }) => {
|
|
176
|
-
const records = window[key].records.filter((r) => r.url === identity.url && r.method === identity.method && !r.aborted);
|
|
177
|
-
const latest = records.at(-1);
|
|
178
|
-
return latest?.failed ? latest.status : null;
|
|
179
|
-
}, { key, identity });
|
|
180
|
-
if (failure !== null)
|
|
181
|
-
throw new Error(`HTMX request failed: ${failure} ${response.url()}`);
|
|
182
|
-
if (!response.ok())
|
|
183
|
-
throw new Error(`HTMX request failed: ${response.status()} ${response.url()}`);
|
|
184
|
-
return response;
|
|
185
|
-
}
|
|
186
|
-
finally {
|
|
187
|
-
await page.evaluate(key => { window[key]?.dispose(); delete window[key]; }, key);
|
|
188
|
-
}
|
|
189
|
-
}
|
|
1
|
+
export { actionAndResponse, actionAndHtmxSettled, actionAndHtmxResponse, actionAndValidationRefusal } from './htmx.js';
|
|
2
|
+
export { expectComponentReady, expectFontsReady, expectChartsReady, openComponentCase, componentCase, assertCaseCoverage, attachDiagnosticScreenshot, ReadinessError } from './components.js';
|
|
190
3
|
/** Teardown runs even when readiness, the scenario or the browser assertion fails. */
|
|
191
4
|
export async function withEnvironment(lifecycle, workerIndex, use) {
|
|
192
5
|
return withEnvironmentLease(lifecycle, workerIndex, use);
|
|
@@ -210,20 +23,4 @@ export { createEnvironmentTest, createEnvironmentLeaseTest } from './fixtures.js
|
|
|
210
23
|
export { createProcessEnvironmentDriver, DriverError } from './driver.js';
|
|
211
24
|
import { preservingCleanup, withEnvironmentLease } from './lease.js';
|
|
212
25
|
export { acquireEnvironmentLease, withEnvironmentLease, preservingCleanup } from './lease.js';
|
|
213
|
-
export
|
|
214
|
-
await page.waitForFunction(() => document.fonts.status === 'loaded', undefined, { timeout: timeout(options) });
|
|
215
|
-
}
|
|
216
|
-
export async function expectChartsReady(charts, options = {}) {
|
|
217
|
-
await waitForCondition(async () => charts.evaluateAll((elements, allowEmpty) => (allowEmpty || elements.length > 0) && elements.every(element => element.getAttribute('data-chart-ready') === 'true'), options.allowEmpty ?? false), timeout(options), 'Chart readiness missing');
|
|
218
|
-
if (!options.allowEmpty)
|
|
219
|
-
await charts.first().waitFor({ state: 'visible', timeout: timeout(options) });
|
|
220
|
-
}
|
|
221
|
-
async function waitForCondition(condition, timeoutMs, diagnostic) {
|
|
222
|
-
const deadline = Date.now() + timeoutMs;
|
|
223
|
-
while (!(await condition())) {
|
|
224
|
-
if (Date.now() >= deadline)
|
|
225
|
-
throw new Error(diagnostic);
|
|
226
|
-
await new Promise(resolve => setTimeout(resolve, Math.min(16, Math.max(1, deadline - Date.now()))));
|
|
227
|
-
}
|
|
228
|
-
}
|
|
229
|
-
export { createHttpScenarioControl, ScenarioControlError } from './scenarios.js';
|
|
26
|
+
export { createHttpScenarioControl, createHttpTestControls, ScenarioControlError, JobWaitError } from './scenarios.js';
|
|
@@ -27,3 +27,86 @@ export declare function createHttpScenarioControl<Data = Record<string, unknown>
|
|
|
27
27
|
environmentId: string;
|
|
28
28
|
baseURL: string;
|
|
29
29
|
}, token: string, options?: WaitOptions): ScenarioControl<ScenarioInput, ScenarioResult<Data>>;
|
|
30
|
+
export type EntityRef = {
|
|
31
|
+
kind: string;
|
|
32
|
+
id: string;
|
|
33
|
+
};
|
|
34
|
+
export type ExecutionStatus = {
|
|
35
|
+
executionId: string;
|
|
36
|
+
scopeId: string;
|
|
37
|
+
job: string;
|
|
38
|
+
state: 'running' | 'succeeded' | 'failed' | 'canceled';
|
|
39
|
+
error?: string;
|
|
40
|
+
startedAt: string;
|
|
41
|
+
finishedAt?: string;
|
|
42
|
+
};
|
|
43
|
+
export type WaitResult = {
|
|
44
|
+
outcome: 'reached' | 'failed' | 'timeout' | 'canceled';
|
|
45
|
+
condition: string;
|
|
46
|
+
execution: ExecutionStatus;
|
|
47
|
+
checks: number;
|
|
48
|
+
lastConditionError?: string;
|
|
49
|
+
elapsedMs: number;
|
|
50
|
+
};
|
|
51
|
+
export type ProviderStep = {
|
|
52
|
+
operation?: string;
|
|
53
|
+
outcome: 'success' | 'refusal' | 'timeout';
|
|
54
|
+
hold?: string;
|
|
55
|
+
response?: Record<string, unknown>;
|
|
56
|
+
};
|
|
57
|
+
export type ProviderCall = {
|
|
58
|
+
sequence: number;
|
|
59
|
+
operation: string;
|
|
60
|
+
key: string;
|
|
61
|
+
outcome: string;
|
|
62
|
+
correlation: string;
|
|
63
|
+
hold?: string;
|
|
64
|
+
};
|
|
65
|
+
export type ScenarioManifest = {
|
|
66
|
+
format: string;
|
|
67
|
+
environment: Record<string, string>;
|
|
68
|
+
scenario: ScenarioInput & {
|
|
69
|
+
scopeId: string;
|
|
70
|
+
};
|
|
71
|
+
result: ScenarioResult;
|
|
72
|
+
controls: {
|
|
73
|
+
clock?: string;
|
|
74
|
+
resources?: Record<string, unknown>;
|
|
75
|
+
};
|
|
76
|
+
};
|
|
77
|
+
/** Typed failure of a job wait; `result` carries the execution diagnostics. */
|
|
78
|
+
export declare class JobWaitError extends ScenarioControlError {
|
|
79
|
+
readonly result: WaitResult;
|
|
80
|
+
constructor(code: string, status: number, message: string, result: WaitResult);
|
|
81
|
+
}
|
|
82
|
+
/**
|
|
83
|
+
* Scoped jobs, provider fakes, the dedicated clock and replay manifests of an
|
|
84
|
+
* isolated environment. Every call names its physical scope; the server checks
|
|
85
|
+
* that the scope belongs to this environment and credential.
|
|
86
|
+
*/
|
|
87
|
+
export declare function createHttpTestControls(environment: {
|
|
88
|
+
environmentId: string;
|
|
89
|
+
baseURL: string;
|
|
90
|
+
}, token: string, options?: WaitOptions): {
|
|
91
|
+
describe: () => Promise<Record<string, unknown>>;
|
|
92
|
+
jobs: {
|
|
93
|
+
run: (scopeId: string, job: string, refs?: Record<string, EntityRef>) => Promise<string>;
|
|
94
|
+
status: (scopeId: string, executionId: string) => Promise<ExecutionStatus>;
|
|
95
|
+
/** Resolves when reached; rejects with JobWaitError on failed or timeout. */
|
|
96
|
+
wait: (scopeId: string, executionId: string, condition: string, waitMs: number) => Promise<WaitResult>;
|
|
97
|
+
};
|
|
98
|
+
providers: {
|
|
99
|
+
script: (scopeId: string, name: string, steps: ProviderStep[]) => Promise<void>;
|
|
100
|
+
calls: (scopeId: string, name: string) => Promise<ProviderCall[]>;
|
|
101
|
+
waitHeld: (scopeId: string, name: string, gate: string, waitMs: number) => Promise<void>;
|
|
102
|
+
release: (scopeId: string, name: string, gate: string) => Promise<void>;
|
|
103
|
+
forget: (scopeId: string) => Promise<void>;
|
|
104
|
+
};
|
|
105
|
+
clock: {
|
|
106
|
+
/** Server time; pass it to Playwright's page.clock so browser and scenario time agree. */
|
|
107
|
+
now: () => Promise<Date>;
|
|
108
|
+
advance: (scopeId: string, durationMs: number) => Promise<Date>;
|
|
109
|
+
};
|
|
110
|
+
manifest: (scopeId: string) => Promise<ScenarioManifest>;
|
|
111
|
+
replay: (scopeId: string, manifest: ScenarioManifest) => Promise<ScenarioResult<Record<string, unknown>>>;
|
|
112
|
+
};
|
|
@@ -36,3 +36,77 @@ export function createHttpScenarioControl(environment, token, options = {}) {
|
|
|
36
36
|
dispose: async (scopeId) => { await invoke(`/__test__/scopes/${encodeURIComponent(scopeId)}`, 'DELETE'); },
|
|
37
37
|
};
|
|
38
38
|
}
|
|
39
|
+
/** Typed failure of a job wait; `result` carries the execution diagnostics. */
|
|
40
|
+
export class JobWaitError extends ScenarioControlError {
|
|
41
|
+
result;
|
|
42
|
+
constructor(code, status, message, result) {
|
|
43
|
+
super(code, status, message);
|
|
44
|
+
this.result = result;
|
|
45
|
+
this.name = 'JobWaitError';
|
|
46
|
+
}
|
|
47
|
+
}
|
|
48
|
+
/**
|
|
49
|
+
* Scoped jobs, provider fakes, the dedicated clock and replay manifests of an
|
|
50
|
+
* isolated environment. Every call names its physical scope; the server checks
|
|
51
|
+
* that the scope belongs to this environment and credential.
|
|
52
|
+
*/
|
|
53
|
+
export function createHttpTestControls(environment, token, options = {}) {
|
|
54
|
+
const timeoutMs = options.timeoutMs ?? 10_000;
|
|
55
|
+
if (!Number.isInteger(timeoutMs) || timeoutMs <= 0 || token.length < 32)
|
|
56
|
+
throw new Error('A positive timeout and a control credential of at least 32 characters are required');
|
|
57
|
+
const invoke = async (pathname, method, body, requestTimeoutMs = timeoutMs) => {
|
|
58
|
+
const response = await fetch(new URL(pathname, environment.baseURL), { method, redirect: 'manual', signal: AbortSignal.timeout(requestTimeoutMs),
|
|
59
|
+
headers: { Authorization: `Bearer ${token}`, ...(body === undefined ? {} : { 'Content-Type': 'application/json' }) }, body: body === undefined ? undefined : JSON.stringify(body) });
|
|
60
|
+
const text = await response.text();
|
|
61
|
+
let payload = {};
|
|
62
|
+
let parsed = false;
|
|
63
|
+
try {
|
|
64
|
+
payload = JSON.parse(text);
|
|
65
|
+
parsed = payload !== null && typeof payload === 'object' && !Array.isArray(payload);
|
|
66
|
+
}
|
|
67
|
+
catch { }
|
|
68
|
+
if (!response.ok) {
|
|
69
|
+
const code = typeof payload.code === 'string' ? payload.code : `http_${response.status}`;
|
|
70
|
+
const message = typeof payload.message === 'string' ? payload.message : `Test control returned HTTP ${response.status}`;
|
|
71
|
+
if (payload.details && typeof payload.details === 'object' && 'outcome' in payload.details)
|
|
72
|
+
throw new JobWaitError(code, response.status, message, payload.details);
|
|
73
|
+
throw new ScenarioControlError(code, response.status, message);
|
|
74
|
+
}
|
|
75
|
+
if (response.headers.get('X-Test-Environment-ID') !== environment.environmentId)
|
|
76
|
+
throw new ScenarioControlError('environment_mismatch', response.status, 'Test control endpoint belongs to another environment');
|
|
77
|
+
// A successful control answer is always a JSON object; anything else is a broken endpoint, not an empty result.
|
|
78
|
+
if (!parsed)
|
|
79
|
+
throw new ScenarioControlError('invalid_response', response.status, 'Test control returned a malformed JSON body');
|
|
80
|
+
return payload;
|
|
81
|
+
};
|
|
82
|
+
const scope = (scopeId) => `/__test__/scopes/${encodeURIComponent(scopeId)}`;
|
|
83
|
+
const provider = (scopeId, name) => `${scope(scopeId)}/providers/${encodeURIComponent(name)}`;
|
|
84
|
+
const boundedWait = (ms) => { if (!Number.isInteger(ms) || ms < 1 || ms > 120_000)
|
|
85
|
+
throw new Error('timeoutMs must be an integer from 1 to 120000'); return ms; };
|
|
86
|
+
return {
|
|
87
|
+
describe: () => invoke('/__test__/controls', 'GET'),
|
|
88
|
+
jobs: {
|
|
89
|
+
run: async (scopeId, job, refs = {}) => (await invoke(`${scope(scopeId)}/jobs`, 'POST', { job, refs })).executionId,
|
|
90
|
+
status: (scopeId, executionId) => invoke(`${scope(scopeId)}/executions/${encodeURIComponent(executionId)}`, 'GET'),
|
|
91
|
+
/** Resolves when reached; rejects with JobWaitError on failed or timeout. */
|
|
92
|
+
wait: (scopeId, executionId, condition, waitMs) => invoke(`${scope(scopeId)}/executions/${encodeURIComponent(executionId)}/wait`, 'POST', { condition, timeoutMs: boundedWait(waitMs) }, boundedWait(waitMs) + timeoutMs),
|
|
93
|
+
},
|
|
94
|
+
providers: {
|
|
95
|
+
script: async (scopeId, name, steps) => { await invoke(`${provider(scopeId, name)}/scripts`, 'POST', { steps }); },
|
|
96
|
+
calls: async (scopeId, name) => (await invoke(`${provider(scopeId, name)}/calls`, 'GET')).calls,
|
|
97
|
+
waitHeld: async (scopeId, name, gate, waitMs) => { await invoke(`${provider(scopeId, name)}/gates/${encodeURIComponent(gate)}/wait`, 'POST', { timeoutMs: boundedWait(waitMs) }, boundedWait(waitMs) + timeoutMs); },
|
|
98
|
+
release: async (scopeId, name, gate) => { await invoke(`${provider(scopeId, name)}/gates/${encodeURIComponent(gate)}/release`, 'POST'); },
|
|
99
|
+
forget: async (scopeId) => { await invoke(`${scope(scopeId)}/providers`, 'DELETE'); },
|
|
100
|
+
},
|
|
101
|
+
clock: {
|
|
102
|
+
/** Server time; pass it to Playwright's page.clock so browser and scenario time agree. */
|
|
103
|
+
now: async () => new Date((await invoke('/__test__/clock', 'GET')).now),
|
|
104
|
+
advance: async (scopeId, durationMs) => new Date((await invoke(`${scope(scopeId)}/clock/advance`, 'POST', { durationMs })).now),
|
|
105
|
+
},
|
|
106
|
+
manifest: (scopeId) => invoke(`${scope(scopeId)}/manifest`, 'GET'),
|
|
107
|
+
replay: async (scopeId, manifest) => {
|
|
108
|
+
await invoke('/__test__/scopes', 'POST', { scopeId });
|
|
109
|
+
return await invoke(`${scope(scopeId)}/replay`, 'POST', manifest);
|
|
110
|
+
},
|
|
111
|
+
};
|
|
112
|
+
}
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
export type WaitOptions = {
|
|
2
|
+
timeoutMs?: number;
|
|
3
|
+
};
|
|
4
|
+
export declare function timeout(options?: WaitOptions): number;
|
|
5
|
+
/** One budget for a multi-step wait: later steps receive what the earlier ones left. */
|
|
6
|
+
export declare function deadline(options?: WaitOptions): () => number;
|
|
7
|
+
export declare function waitForCondition(condition: () => Promise<boolean>, timeoutMs: number, diagnostic: () => Promise<Error> | Error): Promise<void>;
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
export function timeout(options = {}) {
|
|
2
|
+
const value = options.timeoutMs ?? 10_000;
|
|
3
|
+
if (!Number.isInteger(value) || value <= 0)
|
|
4
|
+
throw new Error('timeoutMs must be a positive integer');
|
|
5
|
+
return value;
|
|
6
|
+
}
|
|
7
|
+
/** One budget for a multi-step wait: later steps receive what the earlier ones left. */
|
|
8
|
+
export function deadline(options = {}) {
|
|
9
|
+
const end = Date.now() + timeout(options);
|
|
10
|
+
return () => Math.max(1, end - Date.now());
|
|
11
|
+
}
|
|
12
|
+
export async function waitForCondition(condition, timeoutMs, diagnostic) {
|
|
13
|
+
const end = Date.now() + timeoutMs;
|
|
14
|
+
while (!(await condition())) {
|
|
15
|
+
if (Date.now() >= end)
|
|
16
|
+
throw await diagnostic();
|
|
17
|
+
await new Promise(resolve => setTimeout(resolve, Math.min(16, Math.max(1, end - Date.now()))));
|
|
18
|
+
}
|
|
19
|
+
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@iota-uz/sdk",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.47.0",
|
|
4
4
|
"description": "Canonical JavaScript distribution for iota-sdk.",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"repository": {
|
|
@@ -13,6 +13,9 @@
|
|
|
13
13
|
"provenance": true
|
|
14
14
|
},
|
|
15
15
|
"type": "module",
|
|
16
|
+
"bin": {
|
|
17
|
+
"iota-ext": "./dist/runtime/cli/iota-ext.mjs"
|
|
18
|
+
},
|
|
16
19
|
"packageManager": "pnpm@9.15.0",
|
|
17
20
|
"engines": {
|
|
18
21
|
"node": ">=20.19.0"
|
|
@@ -39,6 +42,10 @@
|
|
|
39
42
|
"import": "./dist/solid-ui/index.js"
|
|
40
43
|
},
|
|
41
44
|
"./solid-ui/standalone.css": "./dist/solid-ui/standalone.css",
|
|
45
|
+
"./solid-ui/embedded-css": {
|
|
46
|
+
"types": "./dist/solid-ui/embedded-css.d.ts",
|
|
47
|
+
"import": "./dist/solid-ui/embedded-css.js"
|
|
48
|
+
},
|
|
42
49
|
"./styles.css": "./dist/styles.css",
|
|
43
50
|
"./identity": {
|
|
44
51
|
"types": "./dist/sdk-identity.d.ts",
|
|
@@ -54,6 +61,26 @@
|
|
|
54
61
|
"types": "./dist/testing/index.d.ts",
|
|
55
62
|
"import": "./dist/testing/index.js"
|
|
56
63
|
},
|
|
64
|
+
"./runtime": {
|
|
65
|
+
"types": "./dist/runtime/index.d.ts",
|
|
66
|
+
"import": "./dist/runtime/index.js"
|
|
67
|
+
},
|
|
68
|
+
"./runtime/server": {
|
|
69
|
+
"types": "./dist/runtime/server.d.ts",
|
|
70
|
+
"import": "./dist/runtime/server.js"
|
|
71
|
+
},
|
|
72
|
+
"./runtime/client": {
|
|
73
|
+
"types": "./dist/runtime/client.d.ts",
|
|
74
|
+
"import": "./dist/runtime/client.js"
|
|
75
|
+
},
|
|
76
|
+
"./runtime/kit": {
|
|
77
|
+
"types": "./dist/runtime/kit.d.ts",
|
|
78
|
+
"import": "./dist/runtime/kit.js"
|
|
79
|
+
},
|
|
80
|
+
"./runtime/testing": {
|
|
81
|
+
"types": "./dist/runtime/testing.d.ts",
|
|
82
|
+
"import": "./dist/runtime/testing.js"
|
|
83
|
+
},
|
|
57
84
|
"./chat-ui": {
|
|
58
85
|
"types": "./dist/chat-ui/index.d.ts",
|
|
59
86
|
"import": "./dist/chat-ui/index.js"
|
|
@@ -66,7 +93,8 @@
|
|
|
66
93
|
},
|
|
67
94
|
"peerDependencies": {
|
|
68
95
|
"solid-js": "^1.9.0",
|
|
69
|
-
"@playwright/test": "^1.55.0"
|
|
96
|
+
"@playwright/test": "^1.55.0",
|
|
97
|
+
"esbuild": "^0.25.0"
|
|
70
98
|
},
|
|
71
99
|
"peerDependenciesMeta": {
|
|
72
100
|
"solid-js": {
|
|
@@ -74,6 +102,9 @@
|
|
|
74
102
|
},
|
|
75
103
|
"@playwright/test": {
|
|
76
104
|
"optional": true
|
|
105
|
+
},
|
|
106
|
+
"esbuild": {
|
|
107
|
+
"optional": true
|
|
77
108
|
}
|
|
78
109
|
}
|
|
79
110
|
}
|