@cartanova/qgrid-cli 2.10.9 → 2.11.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/bundle/dist/_virtual/_rolldown/runtime.js +1 -10
- package/bundle/dist/application/monit/log-buffer.js +12 -6
- package/bundle/dist/application/monit/monit.frame.js +11 -3
- package/bundle/dist/application/monit/monit.types.js +1 -1
- package/bundle/dist/application/qgrid/conv-routing.js +9 -6
- package/bundle/dist/application/qgrid/expired-token-reminder.js +2 -2
- package/bundle/dist/application/qgrid/oauth.js +31 -4
- package/bundle/dist/application/qgrid/qgrid-image-generation.js +1 -1
- package/bundle/dist/application/qgrid/qgrid-response-format.js +22 -20
- package/bundle/dist/application/qgrid/qgrid-run-lifecycle.js +43 -34
- package/bundle/dist/application/qgrid/qgrid.dispatcher.js +128 -93
- package/bundle/dist/application/qgrid/qgrid.frame.js +930 -49
- package/bundle/dist/application/qgrid/qgrid.types.js +212 -5
- package/bundle/dist/application/qgrid/schema-prompt.js +75 -48
- package/bundle/dist/application/qgrid/slack-user-map.js +1 -1
- package/bundle/dist/application/qgrid/token-death.js +1 -1
- package/bundle/dist/application/qgrid/token-subscriber.js +83 -30
- package/bundle/dist/application/qgrid/token-trigger-setup.js +1 -1
- package/bundle/dist/application/qgrid/token-window-keepalive.js +8 -6
- package/bundle/dist/application/qgrid/tool-emulation-schema.js +13 -13
- package/bundle/dist/application/qgrid/tool-emulation.js +19 -15
- package/bundle/dist/application/request-log/json-schema-type-text.js +29 -12
- package/bundle/dist/application/request-log/request-log.model.js +83 -69
- package/bundle/dist/application/request-log/request-log.types.js +8 -2
- package/bundle/dist/application/request-log/zod-code-format.js +1 -1
- package/bundle/dist/application/request-log-step/request-log-step.model.js +1 -1
- package/bundle/dist/application/request-log-step/request-log-step.types.js +1 -1
- package/bundle/dist/application/setting/setting.constant.js +1 -1
- package/bundle/dist/application/setting/setting.model.js +2 -2
- package/bundle/dist/application/setting/setting.store.js +2 -2
- package/bundle/dist/application/setting/setting.types.js +1 -1
- package/bundle/dist/application/sonamu.generated.js +40 -16
- package/bundle/dist/application/sonamu.generated.sso.js +2 -1
- package/bundle/dist/application/token/token.model.js +26 -9
- package/bundle/dist/application/token/token.types.js +20 -3
- package/bundle/dist/i18n/en.js +15 -1
- package/bundle/dist/i18n/ko.js +15 -1
- package/bundle/dist/i18n/sd.generated.js +2 -1
- package/bundle/dist/migrations/20260807133553_manual__backfill_request_log_cost.js +8 -6
- package/bundle/dist/migrations/20261018215031_alter_request_logs_add1_alter1.js +15 -0
- package/bundle/dist/server-bootstrap.js +4 -2
- package/bundle/dist/server-error-handler.js +1 -1
- package/bundle/dist/sonamu.config.js +37 -8
- package/bundle/dist/startup-migrations.js +17 -7
- package/bundle/dist/testing/global.js +1 -1
- package/bundle/dist/testing/schema-bench.js +0 -0
- package/bundle/dist/testing/test-database-name.js +1 -1
- package/bundle/dist/utils/providers/anthropic/anthropic-constants.js +1 -1
- package/bundle/dist/utils/providers/anthropic/anthropic-dispatcher.js +11 -5
- package/bundle/dist/utils/providers/anthropic/anthropic-quota.js +4 -4
- package/bundle/dist/utils/providers/anthropic/anthropic-thinking.js +1 -1
- package/bundle/dist/utils/providers/anthropic/claude-session.js +20 -19
- package/bundle/dist/utils/providers/anthropic/fence-strip.js +1 -1
- package/bundle/dist/utils/providers/anthropic/stream-json-adapter.js +49 -23
- package/bundle/dist/utils/providers/common/credentials.js +5 -1
- package/bundle/dist/utils/providers/common/effort.js +3 -3
- package/bundle/dist/utils/providers/common/model-cost.js +69 -14
- package/bundle/dist/utils/providers/common/provider-types.js +29 -1
- package/bundle/dist/utils/providers/common/schema-validation.js +78 -40
- package/bundle/dist/utils/providers/common/smooth-weighted-round-robin.js +1 -1
- package/bundle/dist/utils/providers/common/strictifier.js +62 -43
- package/bundle/dist/utils/providers/common/thinking.js +3 -2
- package/bundle/dist/utils/providers/common/ttft.js +1 -1
- package/bundle/dist/utils/providers/grok/grok-backend-protocol.js +427 -0
- package/bundle/dist/utils/providers/grok/grok-constants.js +55 -0
- package/bundle/dist/utils/providers/grok/grok-direct-client.js +196 -0
- package/bundle/dist/utils/providers/grok/grok-dispatcher.js +1313 -0
- package/bundle/dist/utils/providers/grok/grok-headers.js +118 -0
- package/bundle/dist/utils/providers/grok/grok-media-client.js +420 -0
- package/bundle/dist/utils/providers/grok/grok-models.js +114 -0
- package/bundle/dist/utils/providers/grok/grok-oauth.js +455 -0
- package/bundle/dist/utils/providers/grok/grok-quota.js +119 -0
- package/bundle/dist/utils/providers/grok/grok-refresh.js +192 -0
- package/bundle/dist/utils/providers/grok/grok-types.js +186 -0
- package/bundle/dist/utils/providers/grok/grok-voice-client.js +199 -0
- package/bundle/dist/utils/providers/grok/index.js +11 -0
- package/bundle/dist/utils/providers/openai/openai-backend-protocol.js +111 -83
- package/bundle/dist/utils/providers/openai/openai-callback-relay.js +3 -2
- package/bundle/dist/utils/providers/openai/openai-constants.js +1 -1
- package/bundle/dist/utils/providers/openai/openai-direct-client.js +23 -7
- package/bundle/dist/utils/providers/openai/openai-dispatcher.js +143 -106
- package/bundle/dist/utils/providers/openai/openai-image-generation.js +48 -33
- package/bundle/dist/utils/providers/openai/openai-oauth.js +28 -13
- package/bundle/dist/utils/providers/openai/openai-quota.js +38 -27
- package/bundle/dist/utils/providers/openai/openai-refresh.js +17 -9
- package/bundle/dist/utils/providers/openai/openai-sse.js +1 -1
- package/bundle/dist/utils/providers/openai/openai-transport-config.js +1 -1
- package/bundle/dist/utils/quiet-hours.js +1 -1
- package/bundle/dist/utils/slack-notify.js +14 -8
- package/bundle/dist/utils/subset-loaders.js +4 -5
- package/bundle/src/application/monit/log-buffer.ts +23 -9
- package/bundle/src/application/monit/monit.frame.ts +22 -5
- package/bundle/src/application/monit/monit.types.ts +6 -0
- package/bundle/src/application/qgrid/conv-routing.test.ts +76 -4
- package/bundle/src/application/qgrid/conv-routing.ts +35 -9
- package/bundle/src/application/qgrid/expired-token-reminder.ts +9 -1
- package/bundle/src/application/qgrid/oauth.ts +51 -15
- package/bundle/src/application/qgrid/qgrid-image-generation.ts +9 -0
- package/bundle/src/application/qgrid/qgrid-response-format.ts +50 -25
- package/bundle/src/application/qgrid/qgrid-run-lifecycle.test.ts +33 -0
- package/bundle/src/application/qgrid/qgrid-run-lifecycle.ts +87 -40
- package/bundle/src/application/qgrid/qgrid.dispatcher.test.ts +97 -0
- package/bundle/src/application/qgrid/qgrid.dispatcher.ts +274 -126
- package/bundle/src/application/qgrid/qgrid.frame.test.ts +1013 -3
- package/bundle/src/application/qgrid/qgrid.frame.ts +1415 -60
- package/bundle/src/application/qgrid/qgrid.types.ts +335 -0
- package/bundle/src/application/qgrid/schema-prompt.ts +105 -41
- package/bundle/src/application/qgrid/slack-user-map.ts +5 -0
- package/bundle/src/application/qgrid/token-death.ts +4 -0
- package/bundle/src/application/qgrid/token-subscriber.test.ts +21 -19
- package/bundle/src/application/qgrid/token-subscriber.ts +186 -53
- package/bundle/src/application/qgrid/token-trigger-setup.ts +2 -0
- package/bundle/src/application/qgrid/token-window-keepalive.ts +49 -6
- package/bundle/src/application/qgrid/tool-emulation-schema.ts +33 -29
- package/bundle/src/application/qgrid/tool-emulation.ts +52 -27
- package/bundle/src/application/request-log/json-schema-type-text.test.ts +5 -5
- package/bundle/src/application/request-log/json-schema-type-text.ts +81 -26
- package/bundle/src/application/request-log/request-log.entity.json +8 -0
- package/bundle/src/application/request-log/request-log.model.test.ts +111 -4
- package/bundle/src/application/request-log/request-log.model.ts +279 -145
- package/bundle/src/application/request-log/request-log.types.ts +17 -0
- package/bundle/src/application/request-log/zod-code-format.ts +11 -0
- package/bundle/src/application/request-log-step/request-log-step.model.ts +1 -0
- package/bundle/src/application/request-log-step/request-log-step.types.ts +2 -0
- package/bundle/src/application/setting/setting.constant.ts +9 -0
- package/bundle/src/application/setting/setting.model.ts +12 -2
- package/bundle/src/application/setting/setting.store.ts +5 -1
- package/bundle/src/application/setting/setting.types.ts +8 -0
- package/bundle/src/application/sonamu.generated.http +135 -0
- package/bundle/src/application/sonamu.generated.sso.ts +3 -0
- package/bundle/src/application/sonamu.generated.ts +29 -0
- package/bundle/src/application/token/token.identity.test.ts +20 -0
- package/bundle/src/application/token/token.model.ts +66 -7
- package/bundle/src/application/token/token.types.ts +24 -1
- package/bundle/src/i18n/en.ts +19 -0
- package/bundle/src/i18n/ko.ts +21 -0
- package/bundle/src/i18n/sd.generated.ts +24 -2
- package/bundle/src/migrations/20260807133553_manual__backfill_request_log_cost.ts +16 -8
- package/bundle/src/migrations/20261018215031_alter_request_logs_add1_alter1.ts +15 -0
- package/bundle/src/server-bootstrap.ts +4 -2
- package/bundle/src/server-error-handler.ts +1 -0
- package/bundle/src/sonamu.config.ts +69 -7
- package/bundle/src/startup-migrations.ts +27 -9
- package/bundle/src/testing/global.ts +20 -0
- package/bundle/src/testing/schema-bench.ts +105 -30
- package/bundle/src/testing/test-database-name.ts +2 -0
- package/bundle/src/utils/providers/anthropic/anthropic-constants.ts +8 -0
- package/bundle/src/utils/providers/anthropic/anthropic-dispatcher.ts +41 -6
- package/bundle/src/utils/providers/anthropic/anthropic-quota.ts +7 -3
- package/bundle/src/utils/providers/anthropic/anthropic-thinking.ts +6 -0
- package/bundle/src/utils/providers/anthropic/claude-session.ts +58 -24
- package/bundle/src/utils/providers/anthropic/fence-strip.ts +11 -0
- package/bundle/src/utils/providers/anthropic/stream-json-adapter.ts +110 -45
- package/bundle/src/utils/providers/common/credentials.ts +8 -0
- package/bundle/src/utils/providers/common/effort.ts +9 -2
- package/bundle/src/utils/providers/common/model-cost.test.ts +48 -1
- package/bundle/src/utils/providers/common/model-cost.ts +259 -158
- package/bundle/src/utils/providers/common/provider-dispatcher.ts +98 -2
- package/bundle/src/utils/providers/common/provider-types.ts +46 -3
- package/bundle/src/utils/providers/common/schema-validation.test.ts +5 -1
- package/bundle/src/utils/providers/common/schema-validation.ts +124 -56
- package/bundle/src/utils/providers/common/smooth-weighted-round-robin.ts +4 -0
- package/bundle/src/utils/providers/common/strictifier.ts +185 -59
- package/bundle/src/utils/providers/common/thinking.ts +2 -2
- package/bundle/src/utils/providers/common/ttft.ts +4 -2
- package/bundle/src/utils/providers/grok/__fixtures__/golden-responses-1.0.60.json +164 -0
- package/bundle/src/utils/providers/grok/grok-backend-protocol.test.ts +325 -0
- package/bundle/src/utils/providers/grok/grok-backend-protocol.ts +721 -0
- package/bundle/src/utils/providers/grok/grok-constants.ts +105 -0
- package/bundle/src/utils/providers/grok/grok-direct-client.test.ts +179 -0
- package/bundle/src/utils/providers/grok/grok-direct-client.ts +313 -0
- package/bundle/src/utils/providers/grok/grok-dispatcher.test.ts +1395 -0
- package/bundle/src/utils/providers/grok/grok-dispatcher.ts +2105 -0
- package/bundle/src/utils/providers/grok/grok-headers.test.ts +149 -0
- package/bundle/src/utils/providers/grok/grok-headers.ts +199 -0
- package/bundle/src/utils/providers/grok/grok-media-client.test.ts +446 -0
- package/bundle/src/utils/providers/grok/grok-media-client.ts +703 -0
- package/bundle/src/utils/providers/grok/grok-models.test.ts +96 -0
- package/bundle/src/utils/providers/grok/grok-models.ts +161 -0
- package/bundle/src/utils/providers/grok/grok-oauth.test.ts +406 -0
- package/bundle/src/utils/providers/grok/grok-oauth.ts +771 -0
- package/bundle/src/utils/providers/grok/grok-quota.test.ts +142 -0
- package/bundle/src/utils/providers/grok/grok-quota.ts +198 -0
- package/bundle/src/utils/providers/grok/grok-refresh.test.ts +239 -0
- package/bundle/src/utils/providers/grok/grok-refresh.ts +325 -0
- package/bundle/src/utils/providers/grok/grok-types.test.ts +252 -0
- package/bundle/src/utils/providers/grok/grok-types.ts +374 -0
- package/bundle/src/utils/providers/grok/grok-voice-client.test.ts +321 -0
- package/bundle/src/utils/providers/grok/grok-voice-client.ts +284 -0
- package/bundle/src/utils/providers/grok/index.ts +20 -0
- package/bundle/src/utils/providers/openai/openai-backend-protocol.ts +221 -137
- package/bundle/src/utils/providers/openai/openai-callback-relay.ts +12 -1
- package/bundle/src/utils/providers/openai/openai-constants.ts +2 -0
- package/bundle/src/utils/providers/openai/openai-direct-client.ts +111 -21
- package/bundle/src/utils/providers/openai/openai-dispatcher.ts +322 -169
- package/bundle/src/utils/providers/openai/openai-image-generation.ts +116 -36
- package/bundle/src/utils/providers/openai/openai-oauth.ts +48 -20
- package/bundle/src/utils/providers/openai/openai-quota.ts +77 -46
- package/bundle/src/utils/providers/openai/openai-refresh.ts +42 -18
- package/bundle/src/utils/providers/openai/openai-sse.ts +27 -3
- package/bundle/src/utils/providers/openai/openai-transport-config.ts +2 -0
- package/bundle/src/utils/quiet-hours.ts +12 -1
- package/bundle/src/utils/slack-notify.ts +44 -13
- package/bundle/src/utils/subset-loaders.ts +7 -7
- package/bundle/web-dist/client/assets/clsx-5XM_pHvN.js +1 -0
- package/bundle/web-dist/client/assets/index-BA7uQ-6c.js +31 -0
- package/bundle/web-dist/client/assets/index-Be2qCZmI.css +1 -0
- package/bundle/web-dist/client/assets/logs-C47OJGEI.js +1 -0
- package/bundle/web-dist/client/assets/monit-BS9no0dU.js +4 -0
- package/bundle/web-dist/client/assets/plus-sdACTfH0.js +1 -0
- package/bundle/web-dist/client/assets/refresh-cw-CY8o_1cT.js +1 -0
- package/bundle/web-dist/client/assets/request-model-BRtFuZvj.js +1 -0
- package/bundle/web-dist/client/assets/routes-kqgkUxE8.js +5 -0
- package/bundle/web-dist/client/assets/{services.generated-BsieU37H.js → services.generated-CefiDXEv.js} +5 -5
- package/bundle/web-dist/client/assets/settings-DNDvFGSw.js +1 -0
- package/bundle/web-dist/client/assets/show-u8Np69q3.js +2 -0
- package/bundle/web-dist/client/assets/tokens-QvP410NW.js +1 -0
- package/bundle/web-dist/client/assets/total-cost-MnfKU8IN.js +1 -0
- package/bundle/web-dist/client/assets/use-oauth-login-flow-Bzdh28Ws.js +1 -0
- package/bundle/web-dist/client/assets/use-update-token-mutation-CfJKaxmR.js +1 -0
- package/bundle/web-dist/client/assets/vendor-react-CUFFrVN9.js +244 -0
- package/bundle/web-dist/client/assets/vendor-tanstack-Bf_jag9G.js +1 -0
- package/bundle/web-dist/client/index.html +6 -6
- package/bundle/web-dist/server/assets/clsx-D_N5PN_2.js +16 -0
- package/bundle/web-dist/server/assets/{lazyRouteComponent-Dtd0NR4r.js → lazyRouteComponent-D8iTIHyn.js} +129 -2
- package/bundle/web-dist/server/assets/logs-B3OTd9hy.js +825 -0
- package/bundle/web-dist/server/assets/{monit-DvzribSE.js → monit-B2hqorPe.js} +385 -126
- package/bundle/web-dist/server/assets/plus-DwG7h9kq.js +28 -0
- package/bundle/web-dist/server/assets/{react-dom-B4a6-uuR.js → react-dom-BIYQzBqG.js} +2 -129
- package/bundle/web-dist/server/assets/refresh-cw-mMBkwOq0.js +44 -0
- package/bundle/web-dist/server/assets/{request-model-CbqfnQOJ.js → request-model-I6OdODSH.js} +15 -6
- package/bundle/web-dist/server/assets/{routes-BAPWTizT.js → routes-B95YlUv2.js} +760 -213
- package/bundle/web-dist/server/assets/{services.generated-CEbGjsI0.js → services.generated-DQATJ6qf.js} +12821 -12194
- package/bundle/web-dist/server/assets/settings-C3gbGk0m.js +830 -0
- package/bundle/web-dist/server/assets/{show-CxVZTAdv.js → show-Bxaj3rhH.js} +1355 -419
- package/bundle/web-dist/server/assets/tokens-CZjH3cB7.js +1038 -0
- package/bundle/web-dist/server/assets/total-cost-fTE9Xy82.js +18 -0
- package/bundle/web-dist/server/assets/use-oauth-login-flow-CKDHgc3U.js +2379 -0
- package/bundle/web-dist/server/assets/{use-update-token-mutation-CfYmk_4_.js → use-update-token-mutation-BEbgOzaa.js} +1 -1
- package/bundle/web-dist/server/entry-server.generated.js +4303 -22810
- package/dist/cli.js +9 -9
- package/package.json +4 -11
- package/postinstall.mjs +12 -0
- package/skills/qgrid/SKILL.md +1 -0
- package/skills/qgrid/references/cli-env-and-server-boot.md +4 -1
- package/skills/qgrid/references/decision-rationale.md +24 -1
- package/skills/qgrid/references/grok-runtime.md +89 -0
- package/skills/qgrid/references/provider-runtime-differences.md +30 -29
- package/skills/qgrid/references/repo-map.md +10 -0
- package/skills/qgrid/references/request-log-run-lifecycle.md +1 -1
- package/skills/qgrid/references/sonamu-api-web-flow.md +1 -1
- package/skills/qgrid/references/token-auth-quota-lifecycle.md +56 -3
- package/bundle/dist/node_modules/.pnpm/@jridgewell_sourcemap-codec@1.5.5/node_modules/@jridgewell/sourcemap-codec/dist/sourcemap-codec.js +0 -406
- package/bundle/dist/node_modules/.pnpm/@vitest_expect@4.1.10/node_modules/@vitest/expect/dist/index.js +0 -1507
- package/bundle/dist/node_modules/.pnpm/@vitest_pretty-format@4.1.10/node_modules/@vitest/pretty-format/dist/index.js +0 -887
- package/bundle/dist/node_modules/.pnpm/@vitest_runner@4.1.10/node_modules/@vitest/runner/dist/chunk-artifact.js +0 -2756
- package/bundle/dist/node_modules/.pnpm/@vitest_runner@4.1.10/node_modules/@vitest/runner/dist/index.js +0 -8
- package/bundle/dist/node_modules/.pnpm/@vitest_runner@4.1.10/node_modules/@vitest/runner/dist/utils.js +0 -8
- package/bundle/dist/node_modules/.pnpm/@vitest_snapshot@4.1.10/node_modules/@vitest/snapshot/dist/index.js +0 -922
- package/bundle/dist/node_modules/.pnpm/@vitest_spy@4.1.10/node_modules/@vitest/spy/dist/index.js +0 -386
- package/bundle/dist/node_modules/.pnpm/@vitest_utils@4.1.10/node_modules/@vitest/utils/dist/chunk-pathe.M-eThtNZ.js +0 -121
- package/bundle/dist/node_modules/.pnpm/@vitest_utils@4.1.10/node_modules/@vitest/utils/dist/constants.js +0 -51
- package/bundle/dist/node_modules/.pnpm/@vitest_utils@4.1.10/node_modules/@vitest/utils/dist/diff.js +0 -1317
- package/bundle/dist/node_modules/.pnpm/@vitest_utils@4.1.10/node_modules/@vitest/utils/dist/display.js +0 -561
- package/bundle/dist/node_modules/.pnpm/@vitest_utils@4.1.10/node_modules/@vitest/utils/dist/error.js +0 -40
- package/bundle/dist/node_modules/.pnpm/@vitest_utils@4.1.10/node_modules/@vitest/utils/dist/helpers.js +0 -272
- package/bundle/dist/node_modules/.pnpm/@vitest_utils@4.1.10/node_modules/@vitest/utils/dist/offset.js +0 -27
- package/bundle/dist/node_modules/.pnpm/@vitest_utils@4.1.10/node_modules/@vitest/utils/dist/serialize.js +0 -77
- package/bundle/dist/node_modules/.pnpm/@vitest_utils@4.1.10/node_modules/@vitest/utils/dist/source-map.js +0 -381
- package/bundle/dist/node_modules/.pnpm/@vitest_utils@4.1.10/node_modules/@vitest/utils/dist/timers.js +0 -51
- package/bundle/dist/node_modules/.pnpm/chai@6.2.2/node_modules/chai/index.js +0 -2986
- package/bundle/dist/node_modules/.pnpm/expect-type@1.3.0/node_modules/expect-type/dist/branding.js +0 -10
- package/bundle/dist/node_modules/.pnpm/expect-type@1.3.0/node_modules/expect-type/dist/index.js +0 -109
- package/bundle/dist/node_modules/.pnpm/expect-type@1.3.0/node_modules/expect-type/dist/messages.js +0 -10
- package/bundle/dist/node_modules/.pnpm/expect-type@1.3.0/node_modules/expect-type/dist/overloads.js +0 -10
- package/bundle/dist/node_modules/.pnpm/expect-type@1.3.0/node_modules/expect-type/dist/utils.js +0 -10
- package/bundle/dist/node_modules/.pnpm/magic-string@0.30.21/node_modules/magic-string/dist/magic-string.es.js +0 -1126
- package/bundle/dist/node_modules/.pnpm/pathe@2.0.3/node_modules/pathe/dist/index.js +0 -21
- package/bundle/dist/node_modules/.pnpm/pathe@2.0.3/node_modules/pathe/dist/shared/pathe.M-eThtNZ.js +0 -432
- package/bundle/dist/node_modules/.pnpm/tinybench@2.9.0/node_modules/tinybench/dist/index.js +0 -517
- package/bundle/dist/node_modules/.pnpm/tinyrainbow@3.1.0/node_modules/tinyrainbow/dist/index.js +0 -101
- package/bundle/dist/node_modules/.pnpm/vite@8.0.3_@emnapi_core@1.11.2_@emnapi_runtime@1.11.2_@types_node@25.0.7_esbuild@0.27.4_5b35fc1fb85d2af4d105e0d74f940f50/node_modules/vite/dist/node/module-runner.js +0 -1265
- package/bundle/dist/node_modules/.pnpm/vitest@4.1.10_@opentelemetry_api@1.9.0_@types_node@25.0.7_@vitest_coverage-v8@4.1.10_vi_a1977b93af7bb69308bcb1dbab39b618/node_modules/vitest/dist/chunks/_commonjsHelpers.D26ty3Ew.js +0 -9
- package/bundle/dist/node_modules/.pnpm/vitest@4.1.10_@opentelemetry_api@1.9.0_@types_node@25.0.7_@vitest_coverage-v8@4.1.10_vi_a1977b93af7bb69308bcb1dbab39b618/node_modules/vitest/dist/chunks/benchmark.CX_oY03V.js +0 -41
- package/bundle/dist/node_modules/.pnpm/vitest@4.1.10_@opentelemetry_api@1.9.0_@types_node@25.0.7_@vitest_coverage-v8@4.1.10_vi_a1977b93af7bb69308bcb1dbab39b618/node_modules/vitest/dist/chunks/evaluatedModules.Dg1zASAC.js +0 -19
- package/bundle/dist/node_modules/.pnpm/vitest@4.1.10_@opentelemetry_api@1.9.0_@types_node@25.0.7_@vitest_coverage-v8@4.1.10_vi_a1977b93af7bb69308bcb1dbab39b618/node_modules/vitest/dist/chunks/index.Chj8NDwU.js +0 -202
- package/bundle/dist/node_modules/.pnpm/vitest@4.1.10_@opentelemetry_api@1.9.0_@types_node@25.0.7_@vitest_coverage-v8@4.1.10_vi_a1977b93af7bb69308bcb1dbab39b618/node_modules/vitest/dist/chunks/index.DdgEv5B1.js +0 -46
- package/bundle/dist/node_modules/.pnpm/vitest@4.1.10_@opentelemetry_api@1.9.0_@types_node@25.0.7_@vitest_coverage-v8@4.1.10_vi_a1977b93af7bb69308bcb1dbab39b618/node_modules/vitest/dist/chunks/rpc.MzXet3jl.js +0 -119
- package/bundle/dist/node_modules/.pnpm/vitest@4.1.10_@opentelemetry_api@1.9.0_@types_node@25.0.7_@vitest_coverage-v8@4.1.10_vi_a1977b93af7bb69308bcb1dbab39b618/node_modules/vitest/dist/chunks/test.DNmyFkvJ.js +0 -3044
- package/bundle/dist/node_modules/.pnpm/vitest@4.1.10_@opentelemetry_api@1.9.0_@types_node@25.0.7_@vitest_coverage-v8@4.1.10_vi_a1977b93af7bb69308bcb1dbab39b618/node_modules/vitest/dist/chunks/utils.BX5Fg8C4.js +0 -59
- package/bundle/dist/node_modules/.pnpm/vitest@4.1.10_@opentelemetry_api@1.9.0_@types_node@25.0.7_@vitest_coverage-v8@4.1.10_vi_a1977b93af7bb69308bcb1dbab39b618/node_modules/vitest/dist/index.js +0 -28
- package/bundle/dist/testing/setup-mocks.js +0 -16
- package/bundle/src/testing/setup-mocks.ts +0 -44
- package/bundle/web-dist/client/assets/index-Bw2s88Ot.css +0 -1
- package/bundle/web-dist/client/assets/index-CrXKu_J8.js +0 -106
- package/bundle/web-dist/client/assets/logs-B2SmWJXA.js +0 -1
- package/bundle/web-dist/client/assets/monit-D-JwXXoA.js +0 -1
- package/bundle/web-dist/client/assets/plus-B62CuqT8.js +0 -1
- package/bundle/web-dist/client/assets/refresh-cw-NNcU0Cmq.js +0 -1
- package/bundle/web-dist/client/assets/request-model-CojtinqK.js +0 -1
- package/bundle/web-dist/client/assets/routes-C5r4gTvY.js +0 -5
- package/bundle/web-dist/client/assets/settings-D3tDSAck.js +0 -1
- package/bundle/web-dist/client/assets/show-Cah_kUKC.js +0 -2
- package/bundle/web-dist/client/assets/tokens-DU2Iyxxd.js +0 -1
- package/bundle/web-dist/client/assets/use-oauth-login-flow-D0UaR9_e.js +0 -1
- package/bundle/web-dist/client/assets/use-update-token-mutation-DAq0F8p-.js +0 -1
- package/bundle/web-dist/client/assets/vendor-react-DH4kUfK2.js +0 -9
- package/bundle/web-dist/client/assets/vendor-tanstack-DJRQAbrY.js +0 -1
- package/bundle/web-dist/server/assets/logs-l91avYif.js +0 -509
- package/bundle/web-dist/server/assets/plus-KZrECewT.js +0 -19
- package/bundle/web-dist/server/assets/refresh-cw-BND93JrF.js +0 -23
- package/bundle/web-dist/server/assets/settings-BZR5HSAL.js +0 -461
- package/bundle/web-dist/server/assets/tokens-D1hb4eKk.js +0 -448
- package/bundle/web-dist/server/assets/use-oauth-login-flow-Cvdy0zF8.js +0 -178
- package/dist/cli.d.ts +0 -10
- /package/bundle/web-dist/client/assets/{cost-DH2jZbrw.js → cost-DB3HbU7T.js} +0 -0
- /package/bundle/web-dist/client/assets/{preload-helper-ca-nBW7U.js → preload-helper-DWTEM3RW.js} +0 -0
- /package/bundle/web-dist/server/assets/{cost-eEHeTRT5.js → cost-BC9yzyA9.js} +0 -0
|
@@ -0,0 +1,830 @@
|
|
|
1
|
+
import { F as require_react, N as useQueryClient, a as SettingService, k as require_jsx_dev_runtime, o as TokenService, tt as __toESM } from "./services.generated-DQATJ6qf.js";
|
|
2
|
+
import { s as lucideRotateCcw } from "../entry-server.generated.js";
|
|
3
|
+
import { t as useUpdateTokenMutation } from "./use-update-token-mutation-BEbgOzaa.js";
|
|
4
|
+
import { t as lucidePlus } from "./plus-DwG7h9kq.js";
|
|
5
|
+
//#region ~icons/lucide/eye.jsx
|
|
6
|
+
var import_react = /* @__PURE__ */ __toESM(require_react());
|
|
7
|
+
var import_jsx_dev_runtime = require_jsx_dev_runtime();
|
|
8
|
+
var _jsxFileName$4 = "~icons/lucide/eye.jsx";
|
|
9
|
+
var lucideEye = (props) => /* @__PURE__ */ (0, import_jsx_dev_runtime.jsxDEV)("svg", {
|
|
10
|
+
viewBox: "0 0 24 24",
|
|
11
|
+
width: "1.2em",
|
|
12
|
+
height: "1.2em",
|
|
13
|
+
...props,
|
|
14
|
+
children: /* @__PURE__ */ (0, import_jsx_dev_runtime.jsxDEV)("g", {
|
|
15
|
+
fill: "none",
|
|
16
|
+
stroke: "currentColor",
|
|
17
|
+
strokeLinecap: "round",
|
|
18
|
+
strokeLinejoin: "round",
|
|
19
|
+
strokeWidth: 2,
|
|
20
|
+
children: [/* @__PURE__ */ (0, import_jsx_dev_runtime.jsxDEV)("path", { d: "M2.062 12.348a1 1 0 0 1 0-.696a10.75 10.75 0 0 1 19.876 0a1 1 0 0 1 0 .696a10.75 10.75 0 0 1-19.876 0" }, void 0, false, {
|
|
21
|
+
fileName: _jsxFileName$4,
|
|
22
|
+
lineNumber: 2,
|
|
23
|
+
columnNumber: 191
|
|
24
|
+
}, void 0), /* @__PURE__ */ (0, import_jsx_dev_runtime.jsxDEV)("circle", {
|
|
25
|
+
cx: 12,
|
|
26
|
+
cy: 12,
|
|
27
|
+
r: 3
|
|
28
|
+
}, void 0, false, {
|
|
29
|
+
fileName: _jsxFileName$4,
|
|
30
|
+
lineNumber: 2,
|
|
31
|
+
columnNumber: 305
|
|
32
|
+
}, void 0)]
|
|
33
|
+
}, void 0, true, {
|
|
34
|
+
fileName: _jsxFileName$4,
|
|
35
|
+
lineNumber: 2,
|
|
36
|
+
columnNumber: 93
|
|
37
|
+
}, void 0)
|
|
38
|
+
}, void 0, false, {
|
|
39
|
+
fileName: _jsxFileName$4,
|
|
40
|
+
lineNumber: 2,
|
|
41
|
+
columnNumber: 28
|
|
42
|
+
}, void 0);
|
|
43
|
+
//#endregion
|
|
44
|
+
//#region ~icons/lucide/eye-off.jsx
|
|
45
|
+
var _jsxFileName$3 = "~icons/lucide/eye-off.jsx";
|
|
46
|
+
var lucideEyeOff = (props) => /* @__PURE__ */ (0, import_jsx_dev_runtime.jsxDEV)("svg", {
|
|
47
|
+
viewBox: "0 0 24 24",
|
|
48
|
+
width: "1.2em",
|
|
49
|
+
height: "1.2em",
|
|
50
|
+
...props,
|
|
51
|
+
children: /* @__PURE__ */ (0, import_jsx_dev_runtime.jsxDEV)("g", {
|
|
52
|
+
fill: "none",
|
|
53
|
+
stroke: "currentColor",
|
|
54
|
+
strokeLinecap: "round",
|
|
55
|
+
strokeLinejoin: "round",
|
|
56
|
+
strokeWidth: 2,
|
|
57
|
+
children: [/* @__PURE__ */ (0, import_jsx_dev_runtime.jsxDEV)("path", { d: "M10.733 5.076a10.744 10.744 0 0 1 11.205 6.575a1 1 0 0 1 0 .696a10.8 10.8 0 0 1-1.444 2.49m-6.41-.679a3 3 0 0 1-4.242-4.242" }, void 0, false, {
|
|
58
|
+
fileName: _jsxFileName$3,
|
|
59
|
+
lineNumber: 2,
|
|
60
|
+
columnNumber: 194
|
|
61
|
+
}, void 0), /* @__PURE__ */ (0, import_jsx_dev_runtime.jsxDEV)("path", { d: "M17.479 17.499a10.75 10.75 0 0 1-15.417-5.151a1 1 0 0 1 0-.696a10.75 10.75 0 0 1 4.446-5.143M2 2l20 20" }, void 0, false, {
|
|
62
|
+
fileName: _jsxFileName$3,
|
|
63
|
+
lineNumber: 2,
|
|
64
|
+
columnNumber: 330
|
|
65
|
+
}, void 0)]
|
|
66
|
+
}, void 0, true, {
|
|
67
|
+
fileName: _jsxFileName$3,
|
|
68
|
+
lineNumber: 2,
|
|
69
|
+
columnNumber: 96
|
|
70
|
+
}, void 0)
|
|
71
|
+
}, void 0, false, {
|
|
72
|
+
fileName: _jsxFileName$3,
|
|
73
|
+
lineNumber: 2,
|
|
74
|
+
columnNumber: 31
|
|
75
|
+
}, void 0);
|
|
76
|
+
//#endregion
|
|
77
|
+
//#region ~icons/lucide/minus.jsx
|
|
78
|
+
var _jsxFileName$2 = "~icons/lucide/minus.jsx";
|
|
79
|
+
var lucideMinus = (props) => /* @__PURE__ */ (0, import_jsx_dev_runtime.jsxDEV)("svg", {
|
|
80
|
+
viewBox: "0 0 24 24",
|
|
81
|
+
width: "1.2em",
|
|
82
|
+
height: "1.2em",
|
|
83
|
+
...props,
|
|
84
|
+
children: /* @__PURE__ */ (0, import_jsx_dev_runtime.jsxDEV)("path", {
|
|
85
|
+
fill: "none",
|
|
86
|
+
stroke: "currentColor",
|
|
87
|
+
strokeLinecap: "round",
|
|
88
|
+
strokeLinejoin: "round",
|
|
89
|
+
strokeWidth: 2,
|
|
90
|
+
d: "M5 12h14"
|
|
91
|
+
}, void 0, false, {
|
|
92
|
+
fileName: _jsxFileName$2,
|
|
93
|
+
lineNumber: 2,
|
|
94
|
+
columnNumber: 95
|
|
95
|
+
}, void 0)
|
|
96
|
+
}, void 0, false, {
|
|
97
|
+
fileName: _jsxFileName$2,
|
|
98
|
+
lineNumber: 2,
|
|
99
|
+
columnNumber: 30
|
|
100
|
+
}, void 0);
|
|
101
|
+
//#endregion
|
|
102
|
+
//#region src/components/qgrid/SettingsPanel.tsx
|
|
103
|
+
var _jsxFileName$1 = "/home/runner/work/qgrid/qgrid/packages/web/src/components/qgrid/SettingsPanel.tsx";
|
|
104
|
+
var GROUP_LABELS = new Map([
|
|
105
|
+
["qgrid", "Qgrid"],
|
|
106
|
+
["slack", "Slack 알림"],
|
|
107
|
+
["slackConnection", "Slack 연결"]
|
|
108
|
+
]);
|
|
109
|
+
function maskValue(value) {
|
|
110
|
+
if (!value) return "";
|
|
111
|
+
if (value.length <= 12) return "•".repeat(value.length);
|
|
112
|
+
return `${value.slice(0, 8)}${"•".repeat(12)}${value.slice(-4)}`;
|
|
113
|
+
}
|
|
114
|
+
/** 정수·실수는 타이핑보다 증감이 빠르다. 범위도 버튼이 알아서 지킨다. */
|
|
115
|
+
function Stepper({ value, min, max, step, disabled, onChange }) {
|
|
116
|
+
const current = Number(value);
|
|
117
|
+
const valid = Number.isFinite(current);
|
|
118
|
+
const lower = min ?? Number.NEGATIVE_INFINITY;
|
|
119
|
+
const upper = max ?? Number.POSITIVE_INFINITY;
|
|
120
|
+
const adjust = (delta) => {
|
|
121
|
+
const next = Math.min(Math.max((valid ? current : min ?? 0) + delta, lower), upper);
|
|
122
|
+
onChange(String(Number(next.toFixed(2))));
|
|
123
|
+
};
|
|
124
|
+
return /* @__PURE__ */ (0, import_jsx_dev_runtime.jsxDEV)("div", {
|
|
125
|
+
className: "inline-flex items-center rounded-lg border border-sand-200/80 bg-white overflow-hidden",
|
|
126
|
+
children: [
|
|
127
|
+
/* @__PURE__ */ (0, import_jsx_dev_runtime.jsxDEV)("button", {
|
|
128
|
+
type: "button",
|
|
129
|
+
"aria-label": "감소",
|
|
130
|
+
onClick: () => adjust(-step),
|
|
131
|
+
disabled: disabled || valid && current <= lower,
|
|
132
|
+
className: "size-7 grid place-items-center text-sand-500 hover:bg-sand-100 disabled:opacity-30 disabled:hover:bg-transparent transition-colors duration-150",
|
|
133
|
+
children: /* @__PURE__ */ (0, import_jsx_dev_runtime.jsxDEV)(lucideMinus, { className: "size-3" }, void 0, false, {
|
|
134
|
+
fileName: _jsxFileName$1,
|
|
135
|
+
lineNumber: 64,
|
|
136
|
+
columnNumber: 9
|
|
137
|
+
}, this)
|
|
138
|
+
}, void 0, false, {
|
|
139
|
+
fileName: _jsxFileName$1,
|
|
140
|
+
lineNumber: 57,
|
|
141
|
+
columnNumber: 7
|
|
142
|
+
}, this),
|
|
143
|
+
/* @__PURE__ */ (0, import_jsx_dev_runtime.jsxDEV)("input", {
|
|
144
|
+
value,
|
|
145
|
+
onChange: (e) => onChange(e.target.value),
|
|
146
|
+
disabled,
|
|
147
|
+
inputMode: "decimal",
|
|
148
|
+
className: "w-12 text-center text-[12px] tabular-nums text-sand-800 bg-transparent border-x border-sand-200/80 py-1 focus:outline-none focus:bg-sand-50"
|
|
149
|
+
}, void 0, false, {
|
|
150
|
+
fileName: _jsxFileName$1,
|
|
151
|
+
lineNumber: 66,
|
|
152
|
+
columnNumber: 7
|
|
153
|
+
}, this),
|
|
154
|
+
/* @__PURE__ */ (0, import_jsx_dev_runtime.jsxDEV)("button", {
|
|
155
|
+
type: "button",
|
|
156
|
+
"aria-label": "증가",
|
|
157
|
+
onClick: () => adjust(step),
|
|
158
|
+
disabled: disabled || valid && current >= upper,
|
|
159
|
+
className: "size-7 grid place-items-center text-sand-500 hover:bg-sand-100 disabled:opacity-30 disabled:hover:bg-transparent transition-colors duration-150",
|
|
160
|
+
children: /* @__PURE__ */ (0, import_jsx_dev_runtime.jsxDEV)(lucidePlus, { className: "size-3" }, void 0, false, {
|
|
161
|
+
fileName: _jsxFileName$1,
|
|
162
|
+
lineNumber: 80,
|
|
163
|
+
columnNumber: 9
|
|
164
|
+
}, this)
|
|
165
|
+
}, void 0, false, {
|
|
166
|
+
fileName: _jsxFileName$1,
|
|
167
|
+
lineNumber: 73,
|
|
168
|
+
columnNumber: 7
|
|
169
|
+
}, this)
|
|
170
|
+
]
|
|
171
|
+
}, void 0, true, {
|
|
172
|
+
fileName: _jsxFileName$1,
|
|
173
|
+
lineNumber: 56,
|
|
174
|
+
columnNumber: 5
|
|
175
|
+
}, this);
|
|
176
|
+
}
|
|
177
|
+
/** 고정 선택지. 자유 입력보다 고르는 편이 빠르고, 범위를 벗어난 값이 생기지 않는다. */
|
|
178
|
+
function PresetGroup({ value, presets, disabled, onChange }) {
|
|
179
|
+
const current = Number(value);
|
|
180
|
+
return /* @__PURE__ */ (0, import_jsx_dev_runtime.jsxDEV)("div", {
|
|
181
|
+
className: "segmented-control inline-flex",
|
|
182
|
+
children: presets.map((preset) => /* @__PURE__ */ (0, import_jsx_dev_runtime.jsxDEV)("button", {
|
|
183
|
+
type: "button",
|
|
184
|
+
disabled,
|
|
185
|
+
"data-active": current === preset,
|
|
186
|
+
onClick: () => onChange(String(preset)),
|
|
187
|
+
className: "rounded-[6px] px-2.5 py-1 text-[11px] font-medium tabular-nums text-sand-500 transition-colors hover:text-sand-800 disabled:opacity-50 data-[active=true]:text-sand-900",
|
|
188
|
+
children: preset >= 60 ? `${preset / 60}시간` : `${preset}분`
|
|
189
|
+
}, preset, false, {
|
|
190
|
+
fileName: _jsxFileName$1,
|
|
191
|
+
lineNumber: 103,
|
|
192
|
+
columnNumber: 9
|
|
193
|
+
}, this))
|
|
194
|
+
}, void 0, false, {
|
|
195
|
+
fileName: _jsxFileName$1,
|
|
196
|
+
lineNumber: 101,
|
|
197
|
+
columnNumber: 5
|
|
198
|
+
}, this);
|
|
199
|
+
}
|
|
200
|
+
/** 값이 어디서 왔는지. 되돌림 버튼이 무엇을 지우는지 이 배지가 설명한다. */
|
|
201
|
+
function SourceBadge({ source }) {
|
|
202
|
+
return /* @__PURE__ */ (0, import_jsx_dev_runtime.jsxDEV)("span", {
|
|
203
|
+
className: `text-[10px] px-1.5 py-0.5 rounded ${source === "db" ? "bg-sienna-50 text-sienna-600" : "bg-sand-100 text-sand-500"}`,
|
|
204
|
+
children: source === "db" ? "저장값" : source === "env" ? "환경변수" : "기본값"
|
|
205
|
+
}, void 0, false, {
|
|
206
|
+
fileName: _jsxFileName$1,
|
|
207
|
+
lineNumber: 123,
|
|
208
|
+
columnNumber: 5
|
|
209
|
+
}, this);
|
|
210
|
+
}
|
|
211
|
+
function Toggle({ on, disabled, onChange }) {
|
|
212
|
+
return /* @__PURE__ */ (0, import_jsx_dev_runtime.jsxDEV)("button", {
|
|
213
|
+
type: "button",
|
|
214
|
+
role: "switch",
|
|
215
|
+
"aria-checked": on,
|
|
216
|
+
disabled,
|
|
217
|
+
onClick: () => onChange(!on),
|
|
218
|
+
className: `relative inline-flex h-5 w-9 shrink-0 items-center rounded-full transition-colors duration-200 disabled:opacity-50 ${on ? "bg-sage-400" : "bg-sand-300"}`,
|
|
219
|
+
children: /* @__PURE__ */ (0, import_jsx_dev_runtime.jsxDEV)("span", { className: `inline-block h-3.5 w-3.5 rounded-full bg-white transition-transform duration-200 ${on ? "translate-x-4.5" : "translate-x-0.5"}` }, void 0, false, {
|
|
220
|
+
fileName: _jsxFileName$1,
|
|
221
|
+
lineNumber: 153,
|
|
222
|
+
columnNumber: 7
|
|
223
|
+
}, this)
|
|
224
|
+
}, void 0, false, {
|
|
225
|
+
fileName: _jsxFileName$1,
|
|
226
|
+
lineNumber: 143,
|
|
227
|
+
columnNumber: 5
|
|
228
|
+
}, this);
|
|
229
|
+
}
|
|
230
|
+
function SettingRow({ item, disabled = false }) {
|
|
231
|
+
const [draft, setDraft] = (0, import_react.useState)(null);
|
|
232
|
+
const [revealed, setRevealed] = (0, import_react.useState)(false);
|
|
233
|
+
const [error, setError] = (0, import_react.useState)(null);
|
|
234
|
+
const queryClient = useQueryClient();
|
|
235
|
+
const updateMutation = SettingService.useUpdateSettingMutation();
|
|
236
|
+
const resetMutation = SettingService.useResetSettingMutation();
|
|
237
|
+
const pending = disabled || updateMutation.isPending || resetMutation.isPending;
|
|
238
|
+
const value = draft ?? item.value;
|
|
239
|
+
const dirty = draft !== null && draft !== item.value;
|
|
240
|
+
const invalidate = () => queryClient.invalidateQueries({ queryKey: SettingService.getSettingListQueryOptions().queryKey });
|
|
241
|
+
const commit = async (next) => {
|
|
242
|
+
setError(null);
|
|
243
|
+
try {
|
|
244
|
+
await updateMutation.mutateAsync({
|
|
245
|
+
key: item.key,
|
|
246
|
+
value: next
|
|
247
|
+
});
|
|
248
|
+
await invalidate();
|
|
249
|
+
setDraft(null);
|
|
250
|
+
} catch (e) {
|
|
251
|
+
setError(e instanceof Error ? e.message : String(e));
|
|
252
|
+
}
|
|
253
|
+
};
|
|
254
|
+
const reset = async () => {
|
|
255
|
+
setError(null);
|
|
256
|
+
try {
|
|
257
|
+
await resetMutation.mutateAsync({ key: item.key });
|
|
258
|
+
await invalidate();
|
|
259
|
+
setDraft(null);
|
|
260
|
+
} catch (e) {
|
|
261
|
+
setError(e instanceof Error ? e.message : String(e));
|
|
262
|
+
}
|
|
263
|
+
};
|
|
264
|
+
const isSecret = item.kind === "secret";
|
|
265
|
+
return /* @__PURE__ */ (0, import_jsx_dev_runtime.jsxDEV)("div", {
|
|
266
|
+
className: "px-4 py-3 sm:px-5",
|
|
267
|
+
children: [/* @__PURE__ */ (0, import_jsx_dev_runtime.jsxDEV)("div", {
|
|
268
|
+
className: "flex items-start gap-4",
|
|
269
|
+
children: [/* @__PURE__ */ (0, import_jsx_dev_runtime.jsxDEV)("div", {
|
|
270
|
+
className: "min-w-0 flex-1",
|
|
271
|
+
children: [/* @__PURE__ */ (0, import_jsx_dev_runtime.jsxDEV)("div", {
|
|
272
|
+
className: "flex items-center gap-2",
|
|
273
|
+
children: [
|
|
274
|
+
/* @__PURE__ */ (0, import_jsx_dev_runtime.jsxDEV)("span", {
|
|
275
|
+
className: "text-[13px] text-sand-800",
|
|
276
|
+
children: item.label
|
|
277
|
+
}, void 0, false, {
|
|
278
|
+
fileName: _jsxFileName$1,
|
|
279
|
+
lineNumber: 210,
|
|
280
|
+
columnNumber: 13
|
|
281
|
+
}, this),
|
|
282
|
+
/* @__PURE__ */ (0, import_jsx_dev_runtime.jsxDEV)(SourceBadge, { source: item.source }, void 0, false, {
|
|
283
|
+
fileName: _jsxFileName$1,
|
|
284
|
+
lineNumber: 211,
|
|
285
|
+
columnNumber: 13
|
|
286
|
+
}, this),
|
|
287
|
+
item.applies === "restart" && /* @__PURE__ */ (void 0)("span", {
|
|
288
|
+
className: "text-[10px] text-caution-500",
|
|
289
|
+
title: "저장해도 다음 재시작부터 반영됩니다",
|
|
290
|
+
children: "재시작 필요"
|
|
291
|
+
}, void 0, false, {
|
|
292
|
+
fileName: _jsxFileName$1,
|
|
293
|
+
lineNumber: 213,
|
|
294
|
+
columnNumber: 15
|
|
295
|
+
}, this)
|
|
296
|
+
]
|
|
297
|
+
}, void 0, true, {
|
|
298
|
+
fileName: _jsxFileName$1,
|
|
299
|
+
lineNumber: 209,
|
|
300
|
+
columnNumber: 11
|
|
301
|
+
}, this), item.help && /* @__PURE__ */ (void 0)("p", {
|
|
302
|
+
className: "mt-0.5 text-[11px] text-sand-500",
|
|
303
|
+
children: item.help
|
|
304
|
+
}, void 0, false, {
|
|
305
|
+
fileName: _jsxFileName$1,
|
|
306
|
+
lineNumber: 221,
|
|
307
|
+
columnNumber: 25
|
|
308
|
+
}, this)]
|
|
309
|
+
}, void 0, true, {
|
|
310
|
+
fileName: _jsxFileName$1,
|
|
311
|
+
lineNumber: 208,
|
|
312
|
+
columnNumber: 9
|
|
313
|
+
}, this), /* @__PURE__ */ (0, import_jsx_dev_runtime.jsxDEV)("div", {
|
|
314
|
+
className: "flex items-center gap-1.5 shrink-0",
|
|
315
|
+
children: [
|
|
316
|
+
item.kind === "boolean" && /* @__PURE__ */ (void 0)(Toggle, {
|
|
317
|
+
on: value === "true",
|
|
318
|
+
disabled: pending,
|
|
319
|
+
onChange: (next) => void commit(String(next))
|
|
320
|
+
}, void 0, false, {
|
|
321
|
+
fileName: _jsxFileName$1,
|
|
322
|
+
lineNumber: 227,
|
|
323
|
+
columnNumber: 13
|
|
324
|
+
}, this),
|
|
325
|
+
item.kind === "preset" && /* @__PURE__ */ (void 0)(PresetGroup, {
|
|
326
|
+
value,
|
|
327
|
+
presets: item.presets,
|
|
328
|
+
disabled: pending,
|
|
329
|
+
onChange: (next) => void commit(next)
|
|
330
|
+
}, void 0, false, {
|
|
331
|
+
fileName: _jsxFileName$1,
|
|
332
|
+
lineNumber: 235,
|
|
333
|
+
columnNumber: 13
|
|
334
|
+
}, this),
|
|
335
|
+
(item.kind === "integer" || item.kind === "number") && /* @__PURE__ */ (void 0)(Stepper, {
|
|
336
|
+
value,
|
|
337
|
+
min: item.min,
|
|
338
|
+
max: item.max,
|
|
339
|
+
step: item.kind === "integer" ? 1 : .5,
|
|
340
|
+
disabled: pending,
|
|
341
|
+
onChange: setDraft
|
|
342
|
+
}, void 0, false, {
|
|
343
|
+
fileName: _jsxFileName$1,
|
|
344
|
+
lineNumber: 244,
|
|
345
|
+
columnNumber: 13
|
|
346
|
+
}, this),
|
|
347
|
+
(item.kind === "string" || isSecret) && /* @__PURE__ */ (void 0)("div", {
|
|
348
|
+
className: "relative",
|
|
349
|
+
children: [/* @__PURE__ */ (void 0)("input", {
|
|
350
|
+
value: isSecret && !revealed ? maskValue(value) : value,
|
|
351
|
+
onChange: (e) => setDraft(e.target.value),
|
|
352
|
+
onFocus: () => isSecret && setRevealed(true),
|
|
353
|
+
disabled: pending,
|
|
354
|
+
className: `w-48 sm:w-64 rounded-lg border border-sand-200/80 bg-white py-1.5 pl-2.5 text-[12px] text-sand-800 focus:outline-none focus:border-sienna-300 ${isSecret ? "pr-8 font-mono" : "pr-2.5"}`
|
|
355
|
+
}, void 0, false, {
|
|
356
|
+
fileName: _jsxFileName$1,
|
|
357
|
+
lineNumber: 256,
|
|
358
|
+
columnNumber: 15
|
|
359
|
+
}, this), isSecret && /* @__PURE__ */ (void 0)("button", {
|
|
360
|
+
type: "button",
|
|
361
|
+
"aria-label": revealed ? "값 숨기기" : "값 보기",
|
|
362
|
+
onClick: () => setRevealed((r) => !r),
|
|
363
|
+
className: "absolute right-1.5 top-1/2 -translate-y-1/2 size-6 grid place-items-center text-sand-400 hover:text-sand-600 transition-colors duration-150",
|
|
364
|
+
children: revealed ? /* @__PURE__ */ (void 0)(lucideEyeOff, { className: "size-3.5" }, void 0, false, {
|
|
365
|
+
fileName: _jsxFileName$1,
|
|
366
|
+
lineNumber: 273,
|
|
367
|
+
columnNumber: 21
|
|
368
|
+
}, this) : /* @__PURE__ */ (void 0)(lucideEye, { className: "size-3.5" }, void 0, false, {
|
|
369
|
+
fileName: _jsxFileName$1,
|
|
370
|
+
lineNumber: 275,
|
|
371
|
+
columnNumber: 21
|
|
372
|
+
}, this)
|
|
373
|
+
}, void 0, false, {
|
|
374
|
+
fileName: _jsxFileName$1,
|
|
375
|
+
lineNumber: 266,
|
|
376
|
+
columnNumber: 17
|
|
377
|
+
}, this)]
|
|
378
|
+
}, void 0, true, {
|
|
379
|
+
fileName: _jsxFileName$1,
|
|
380
|
+
lineNumber: 255,
|
|
381
|
+
columnNumber: 13
|
|
382
|
+
}, this),
|
|
383
|
+
dirty && /* @__PURE__ */ (void 0)("button", {
|
|
384
|
+
type: "button",
|
|
385
|
+
onClick: () => void commit(value),
|
|
386
|
+
disabled: pending,
|
|
387
|
+
className: "px-2.5 py-1.5 text-[11px] font-medium rounded-lg bg-sienna-400 text-white hover:bg-sienna-500 disabled:opacity-50 transition-colors duration-150",
|
|
388
|
+
children: updateMutation.isPending ? "저장 중" : "저장"
|
|
389
|
+
}, void 0, false, {
|
|
390
|
+
fileName: _jsxFileName$1,
|
|
391
|
+
lineNumber: 283,
|
|
392
|
+
columnNumber: 13
|
|
393
|
+
}, this),
|
|
394
|
+
!dirty && item.source === "db" && /* @__PURE__ */ (void 0)("button", {
|
|
395
|
+
type: "button",
|
|
396
|
+
title: "저장값을 지웁니다 — 환경변수 또는 기본값으로 돌아갑니다",
|
|
397
|
+
onClick: () => void reset(),
|
|
398
|
+
disabled: pending,
|
|
399
|
+
className: "size-7 grid place-items-center rounded-lg text-sand-400 hover:text-sand-600 hover:bg-sand-100 disabled:opacity-50 transition-colors duration-150",
|
|
400
|
+
children: /* @__PURE__ */ (void 0)(lucideRotateCcw, { className: "size-3.5" }, void 0, false, {
|
|
401
|
+
fileName: _jsxFileName$1,
|
|
402
|
+
lineNumber: 302,
|
|
403
|
+
columnNumber: 15
|
|
404
|
+
}, this)
|
|
405
|
+
}, void 0, false, {
|
|
406
|
+
fileName: _jsxFileName$1,
|
|
407
|
+
lineNumber: 295,
|
|
408
|
+
columnNumber: 13
|
|
409
|
+
}, this)
|
|
410
|
+
]
|
|
411
|
+
}, void 0, true, {
|
|
412
|
+
fileName: _jsxFileName$1,
|
|
413
|
+
lineNumber: 224,
|
|
414
|
+
columnNumber: 9
|
|
415
|
+
}, this)]
|
|
416
|
+
}, void 0, true, {
|
|
417
|
+
fileName: _jsxFileName$1,
|
|
418
|
+
lineNumber: 207,
|
|
419
|
+
columnNumber: 7
|
|
420
|
+
}, this), error && /* @__PURE__ */ (void 0)("p", {
|
|
421
|
+
className: "mt-1.5 text-[11px] text-red-500",
|
|
422
|
+
children: error
|
|
423
|
+
}, void 0, false, {
|
|
424
|
+
fileName: _jsxFileName$1,
|
|
425
|
+
lineNumber: 308,
|
|
426
|
+
columnNumber: 17
|
|
427
|
+
}, this)]
|
|
428
|
+
}, void 0, true, {
|
|
429
|
+
fileName: _jsxFileName$1,
|
|
430
|
+
lineNumber: 206,
|
|
431
|
+
columnNumber: 5
|
|
432
|
+
}, this);
|
|
433
|
+
}
|
|
434
|
+
function KeepaliveTokenSettings({ runnerEnabled }) {
|
|
435
|
+
const queryClient = useQueryClient();
|
|
436
|
+
const [error, setError] = (0, import_react.useState)(null);
|
|
437
|
+
const tokensQuery = TokenService.useTokens("A", {
|
|
438
|
+
orderBy: "ord-asc",
|
|
439
|
+
num: 100
|
|
440
|
+
});
|
|
441
|
+
const updateMutation = useUpdateTokenMutation();
|
|
442
|
+
const anthropicTokens = (tokensQuery.data?.rows ?? []).filter((token) => token.provider === "anthropic");
|
|
443
|
+
const toggle = async (id, keepaliveEnabled) => {
|
|
444
|
+
setError(null);
|
|
445
|
+
try {
|
|
446
|
+
await updateMutation.mutateAsync({
|
|
447
|
+
id,
|
|
448
|
+
keepaliveEnabled
|
|
449
|
+
});
|
|
450
|
+
await queryClient.invalidateQueries({ queryKey: ["Token", "getTokens"] });
|
|
451
|
+
} catch (cause) {
|
|
452
|
+
setError(cause instanceof Error ? cause.message : String(cause));
|
|
453
|
+
}
|
|
454
|
+
};
|
|
455
|
+
return /* @__PURE__ */ (0, import_jsx_dev_runtime.jsxDEV)("div", {
|
|
456
|
+
className: "border-t border-sand-100/80 bg-sand-50/40 px-4 py-3 sm:px-5",
|
|
457
|
+
children: [
|
|
458
|
+
/* @__PURE__ */ (0, import_jsx_dev_runtime.jsxDEV)("div", {
|
|
459
|
+
className: "mb-2 flex items-center justify-between gap-3",
|
|
460
|
+
children: [/* @__PURE__ */ (0, import_jsx_dev_runtime.jsxDEV)("div", { children: [/* @__PURE__ */ (0, import_jsx_dev_runtime.jsxDEV)("p", {
|
|
461
|
+
className: "text-[11px] font-medium text-sand-600",
|
|
462
|
+
children: "토큰별 keepalive"
|
|
463
|
+
}, void 0, false, {
|
|
464
|
+
fileName: _jsxFileName$1,
|
|
465
|
+
lineNumber: 338,
|
|
466
|
+
columnNumber: 11
|
|
467
|
+
}, this), /* @__PURE__ */ (0, import_jsx_dev_runtime.jsxDEV)("p", {
|
|
468
|
+
className: "mt-0.5 text-[10px] text-sand-400",
|
|
469
|
+
children: runnerEnabled ? "켜진 활성 Anthropic 토큰만 5시간 윈도우를 유지합니다" : "이 인스턴스는 keepalive runner로 지정되지 않았습니다"
|
|
470
|
+
}, void 0, false, {
|
|
471
|
+
fileName: _jsxFileName$1,
|
|
472
|
+
lineNumber: 339,
|
|
473
|
+
columnNumber: 11
|
|
474
|
+
}, this)] }, void 0, true, {
|
|
475
|
+
fileName: _jsxFileName$1,
|
|
476
|
+
lineNumber: 337,
|
|
477
|
+
columnNumber: 9
|
|
478
|
+
}, this), /* @__PURE__ */ (0, import_jsx_dev_runtime.jsxDEV)("span", {
|
|
479
|
+
className: `shrink-0 rounded px-1.5 py-0.5 text-[10px] ${runnerEnabled ? "bg-sage-50 text-sage-600" : "bg-sand-100 text-sand-500"}`,
|
|
480
|
+
children: runnerEnabled ? "runner" : "실행 안 함"
|
|
481
|
+
}, void 0, false, {
|
|
482
|
+
fileName: _jsxFileName$1,
|
|
483
|
+
lineNumber: 345,
|
|
484
|
+
columnNumber: 9
|
|
485
|
+
}, this)]
|
|
486
|
+
}, void 0, true, {
|
|
487
|
+
fileName: _jsxFileName$1,
|
|
488
|
+
lineNumber: 336,
|
|
489
|
+
columnNumber: 7
|
|
490
|
+
}, this),
|
|
491
|
+
tokensQuery.isLoading ? /* @__PURE__ */ (0, import_jsx_dev_runtime.jsxDEV)("p", {
|
|
492
|
+
className: "py-2 text-[11px] text-sand-400",
|
|
493
|
+
children: "토큰을 불러오는 중…"
|
|
494
|
+
}, void 0, false, {
|
|
495
|
+
fileName: _jsxFileName$1,
|
|
496
|
+
lineNumber: 355,
|
|
497
|
+
columnNumber: 9
|
|
498
|
+
}, this) : anthropicTokens.length === 0 ? /* @__PURE__ */ (0, import_jsx_dev_runtime.jsxDEV)("p", {
|
|
499
|
+
className: "py-2 text-[11px] text-sand-400",
|
|
500
|
+
children: "등록된 Anthropic 토큰이 없습니다"
|
|
501
|
+
}, void 0, false, {
|
|
502
|
+
fileName: _jsxFileName$1,
|
|
503
|
+
lineNumber: 357,
|
|
504
|
+
columnNumber: 9
|
|
505
|
+
}, this) : /* @__PURE__ */ (0, import_jsx_dev_runtime.jsxDEV)("div", {
|
|
506
|
+
className: "overflow-hidden rounded-lg border border-sand-200/70 bg-white",
|
|
507
|
+
children: anthropicTokens.map((token) => /* @__PURE__ */ (0, import_jsx_dev_runtime.jsxDEV)("div", {
|
|
508
|
+
className: "flex items-center justify-between gap-4 border-b border-sand-100/80 px-3 py-2 last:border-b-0",
|
|
509
|
+
children: [/* @__PURE__ */ (0, import_jsx_dev_runtime.jsxDEV)("div", {
|
|
510
|
+
className: "min-w-0",
|
|
511
|
+
children: [/* @__PURE__ */ (0, import_jsx_dev_runtime.jsxDEV)("span", {
|
|
512
|
+
className: "block truncate text-[12px] text-sand-700",
|
|
513
|
+
children: token.name
|
|
514
|
+
}, void 0, false, {
|
|
515
|
+
fileName: _jsxFileName$1,
|
|
516
|
+
lineNumber: 366,
|
|
517
|
+
columnNumber: 17
|
|
518
|
+
}, this), !token.active && /* @__PURE__ */ (void 0)("span", {
|
|
519
|
+
className: "text-[10px] text-sand-400",
|
|
520
|
+
children: "토큰 비활성"
|
|
521
|
+
}, void 0, false, {
|
|
522
|
+
fileName: _jsxFileName$1,
|
|
523
|
+
lineNumber: 367,
|
|
524
|
+
columnNumber: 35
|
|
525
|
+
}, this)]
|
|
526
|
+
}, void 0, true, {
|
|
527
|
+
fileName: _jsxFileName$1,
|
|
528
|
+
lineNumber: 365,
|
|
529
|
+
columnNumber: 15
|
|
530
|
+
}, this), /* @__PURE__ */ (0, import_jsx_dev_runtime.jsxDEV)(Toggle, {
|
|
531
|
+
on: token.keepalive_enabled,
|
|
532
|
+
disabled: !runnerEnabled || updateMutation.isPending,
|
|
533
|
+
onChange: (next) => void toggle(token.id, next)
|
|
534
|
+
}, void 0, false, {
|
|
535
|
+
fileName: _jsxFileName$1,
|
|
536
|
+
lineNumber: 369,
|
|
537
|
+
columnNumber: 15
|
|
538
|
+
}, this)]
|
|
539
|
+
}, token.id, true, {
|
|
540
|
+
fileName: _jsxFileName$1,
|
|
541
|
+
lineNumber: 361,
|
|
542
|
+
columnNumber: 13
|
|
543
|
+
}, this))
|
|
544
|
+
}, void 0, false, {
|
|
545
|
+
fileName: _jsxFileName$1,
|
|
546
|
+
lineNumber: 359,
|
|
547
|
+
columnNumber: 9
|
|
548
|
+
}, this),
|
|
549
|
+
error && /* @__PURE__ */ (void 0)("p", {
|
|
550
|
+
className: "mt-2 text-[11px] text-red-500",
|
|
551
|
+
children: error
|
|
552
|
+
}, void 0, false, {
|
|
553
|
+
fileName: _jsxFileName$1,
|
|
554
|
+
lineNumber: 378,
|
|
555
|
+
columnNumber: 17
|
|
556
|
+
}, this)
|
|
557
|
+
]
|
|
558
|
+
}, void 0, true, {
|
|
559
|
+
fileName: _jsxFileName$1,
|
|
560
|
+
lineNumber: 335,
|
|
561
|
+
columnNumber: 5
|
|
562
|
+
}, this);
|
|
563
|
+
}
|
|
564
|
+
/** 만료 알림을 주기를 기다리지 않고 지금 보낸다. 설정이 제대로 붙었는지 확인하는 용도. */
|
|
565
|
+
function TriggerReminderButton() {
|
|
566
|
+
const [result, setResult] = (0, import_react.useState)(null);
|
|
567
|
+
const mutation = SettingService.useTriggerExpiryReminderMutation();
|
|
568
|
+
const trigger = async () => {
|
|
569
|
+
setResult(null);
|
|
570
|
+
try {
|
|
571
|
+
const { sent } = await mutation.mutateAsync();
|
|
572
|
+
setResult(sent === 0 ? "재로그인이 필요한 토큰이 없습니다" : `${sent}건 발송`);
|
|
573
|
+
} catch (e) {
|
|
574
|
+
setResult(e instanceof Error ? e.message : String(e));
|
|
575
|
+
}
|
|
576
|
+
};
|
|
577
|
+
return /* @__PURE__ */ (0, import_jsx_dev_runtime.jsxDEV)("div", {
|
|
578
|
+
className: "flex items-center gap-2",
|
|
579
|
+
children: [result && /* @__PURE__ */ (void 0)("span", {
|
|
580
|
+
className: "text-[11px] text-sand-500",
|
|
581
|
+
children: result
|
|
582
|
+
}, void 0, false, {
|
|
583
|
+
fileName: _jsxFileName$1,
|
|
584
|
+
lineNumber: 402,
|
|
585
|
+
columnNumber: 18
|
|
586
|
+
}, this), /* @__PURE__ */ (0, import_jsx_dev_runtime.jsxDEV)("button", {
|
|
587
|
+
type: "button",
|
|
588
|
+
onClick: () => void trigger(),
|
|
589
|
+
disabled: mutation.isPending,
|
|
590
|
+
className: "px-2 py-1 text-[11px] rounded-lg border border-sand-200/80 text-sand-600 hover:bg-sand-100 disabled:opacity-50 transition-colors duration-150",
|
|
591
|
+
children: mutation.isPending ? "보내는 중" : "지금 보내기"
|
|
592
|
+
}, void 0, false, {
|
|
593
|
+
fileName: _jsxFileName$1,
|
|
594
|
+
lineNumber: 403,
|
|
595
|
+
columnNumber: 7
|
|
596
|
+
}, this)]
|
|
597
|
+
}, void 0, true, {
|
|
598
|
+
fileName: _jsxFileName$1,
|
|
599
|
+
lineNumber: 401,
|
|
600
|
+
columnNumber: 5
|
|
601
|
+
}, this);
|
|
602
|
+
}
|
|
603
|
+
function SettingsPanel() {
|
|
604
|
+
const settingsQuery = SettingService.useSettingList();
|
|
605
|
+
const { data, isLoading } = settingsQuery;
|
|
606
|
+
if (isLoading) return /* @__PURE__ */ (0, import_jsx_dev_runtime.jsxDEV)("div", {
|
|
607
|
+
className: "space-y-4",
|
|
608
|
+
children: [0, 1].map((i) => /* @__PURE__ */ (0, import_jsx_dev_runtime.jsxDEV)("div", {
|
|
609
|
+
className: "panel overflow-hidden",
|
|
610
|
+
children: [/* @__PURE__ */ (0, import_jsx_dev_runtime.jsxDEV)("div", {
|
|
611
|
+
className: "panel-header px-4 py-2.5 sm:px-5",
|
|
612
|
+
children: /* @__PURE__ */ (0, import_jsx_dev_runtime.jsxDEV)("div", { className: "h-3 w-24 rounded bg-sand-200 animate-pulse" }, void 0, false, {
|
|
613
|
+
fileName: _jsxFileName$1,
|
|
614
|
+
lineNumber: 425,
|
|
615
|
+
columnNumber: 15
|
|
616
|
+
}, this)
|
|
617
|
+
}, void 0, false, {
|
|
618
|
+
fileName: _jsxFileName$1,
|
|
619
|
+
lineNumber: 424,
|
|
620
|
+
columnNumber: 13
|
|
621
|
+
}, this), /* @__PURE__ */ (0, import_jsx_dev_runtime.jsxDEV)("div", {
|
|
622
|
+
className: "divide-y divide-sand-100/80",
|
|
623
|
+
children: [
|
|
624
|
+
0,
|
|
625
|
+
1,
|
|
626
|
+
2
|
|
627
|
+
].map((j) => /* @__PURE__ */ (0, import_jsx_dev_runtime.jsxDEV)("div", {
|
|
628
|
+
className: "px-4 py-3 sm:px-5 flex items-center justify-between gap-4",
|
|
629
|
+
children: [/* @__PURE__ */ (0, import_jsx_dev_runtime.jsxDEV)("div", { className: "h-3 w-40 rounded bg-sand-100 animate-pulse" }, void 0, false, {
|
|
630
|
+
fileName: _jsxFileName$1,
|
|
631
|
+
lineNumber: 430,
|
|
632
|
+
columnNumber: 19
|
|
633
|
+
}, this), /* @__PURE__ */ (0, import_jsx_dev_runtime.jsxDEV)("div", { className: "h-7 w-24 rounded-lg bg-sand-100 animate-pulse" }, void 0, false, {
|
|
634
|
+
fileName: _jsxFileName$1,
|
|
635
|
+
lineNumber: 431,
|
|
636
|
+
columnNumber: 19
|
|
637
|
+
}, this)]
|
|
638
|
+
}, j, true, {
|
|
639
|
+
fileName: _jsxFileName$1,
|
|
640
|
+
lineNumber: 429,
|
|
641
|
+
columnNumber: 17
|
|
642
|
+
}, this))
|
|
643
|
+
}, void 0, false, {
|
|
644
|
+
fileName: _jsxFileName$1,
|
|
645
|
+
lineNumber: 427,
|
|
646
|
+
columnNumber: 13
|
|
647
|
+
}, this)]
|
|
648
|
+
}, i, true, {
|
|
649
|
+
fileName: _jsxFileName$1,
|
|
650
|
+
lineNumber: 423,
|
|
651
|
+
columnNumber: 11
|
|
652
|
+
}, this))
|
|
653
|
+
}, void 0, false, {
|
|
654
|
+
fileName: _jsxFileName$1,
|
|
655
|
+
lineNumber: 421,
|
|
656
|
+
columnNumber: 7
|
|
657
|
+
}, this);
|
|
658
|
+
if (settingsQuery.isError && !data) return /* @__PURE__ */ (0, import_jsx_dev_runtime.jsxDEV)("div", {
|
|
659
|
+
className: "panel px-5 py-6 text-center",
|
|
660
|
+
children: [
|
|
661
|
+
/* @__PURE__ */ (0, import_jsx_dev_runtime.jsxDEV)("p", {
|
|
662
|
+
className: "text-[13px] font-medium text-sand-800",
|
|
663
|
+
children: "설정을 불러오지 못했습니다"
|
|
664
|
+
}, void 0, false, {
|
|
665
|
+
fileName: _jsxFileName$1,
|
|
666
|
+
lineNumber: 444,
|
|
667
|
+
columnNumber: 9
|
|
668
|
+
}, this),
|
|
669
|
+
/* @__PURE__ */ (0, import_jsx_dev_runtime.jsxDEV)("p", {
|
|
670
|
+
className: "mt-1 text-[11px] text-red-500",
|
|
671
|
+
children: settingsQuery.error.message
|
|
672
|
+
}, void 0, false, {
|
|
673
|
+
fileName: _jsxFileName$1,
|
|
674
|
+
lineNumber: 445,
|
|
675
|
+
columnNumber: 9
|
|
676
|
+
}, this),
|
|
677
|
+
/* @__PURE__ */ (0, import_jsx_dev_runtime.jsxDEV)("button", {
|
|
678
|
+
type: "button",
|
|
679
|
+
onClick: () => void settingsQuery.refetch(),
|
|
680
|
+
disabled: settingsQuery.isFetching,
|
|
681
|
+
className: "mt-3 px-3 py-1.5 text-[12px] rounded-lg border border-sand-200 text-sand-600 hover:bg-sand-100 disabled:opacity-50",
|
|
682
|
+
children: settingsQuery.isFetching ? "다시 불러오는 중" : "다시 시도"
|
|
683
|
+
}, void 0, false, {
|
|
684
|
+
fileName: _jsxFileName$1,
|
|
685
|
+
lineNumber: 446,
|
|
686
|
+
columnNumber: 9
|
|
687
|
+
}, this)
|
|
688
|
+
]
|
|
689
|
+
}, void 0, true, {
|
|
690
|
+
fileName: _jsxFileName$1,
|
|
691
|
+
lineNumber: 443,
|
|
692
|
+
columnNumber: 7
|
|
693
|
+
}, this);
|
|
694
|
+
const settings = data?.settings ?? [];
|
|
695
|
+
const runtime = data?.runtime ?? [];
|
|
696
|
+
const groups = [...new Set(settings.map((s) => s.group))];
|
|
697
|
+
return /* @__PURE__ */ (0, import_jsx_dev_runtime.jsxDEV)("div", {
|
|
698
|
+
className: "space-y-4",
|
|
699
|
+
children: [/* @__PURE__ */ (0, import_jsx_dev_runtime.jsxDEV)("div", {
|
|
700
|
+
className: "panel overflow-hidden",
|
|
701
|
+
children: [/* @__PURE__ */ (0, import_jsx_dev_runtime.jsxDEV)("div", {
|
|
702
|
+
className: "panel-header flex items-center justify-between px-4 py-2.5 sm:px-5",
|
|
703
|
+
children: [/* @__PURE__ */ (0, import_jsx_dev_runtime.jsxDEV)("span", {
|
|
704
|
+
className: "text-[13px] font-medium text-sand-700",
|
|
705
|
+
children: "환경"
|
|
706
|
+
}, void 0, false, {
|
|
707
|
+
fileName: _jsxFileName$1,
|
|
708
|
+
lineNumber: 466,
|
|
709
|
+
columnNumber: 11
|
|
710
|
+
}, this), /* @__PURE__ */ (0, import_jsx_dev_runtime.jsxDEV)("span", {
|
|
711
|
+
className: "text-[11px] text-sand-400",
|
|
712
|
+
children: "기동 시점 값"
|
|
713
|
+
}, void 0, false, {
|
|
714
|
+
fileName: _jsxFileName$1,
|
|
715
|
+
lineNumber: 467,
|
|
716
|
+
columnNumber: 11
|
|
717
|
+
}, this)]
|
|
718
|
+
}, void 0, true, {
|
|
719
|
+
fileName: _jsxFileName$1,
|
|
720
|
+
lineNumber: 465,
|
|
721
|
+
columnNumber: 9
|
|
722
|
+
}, this), /* @__PURE__ */ (0, import_jsx_dev_runtime.jsxDEV)("dl", {
|
|
723
|
+
className: "px-4 py-3 sm:px-5 grid grid-cols-1 sm:grid-cols-2 gap-x-8 gap-y-1.5",
|
|
724
|
+
children: runtime.map((info) => /* @__PURE__ */ (0, import_jsx_dev_runtime.jsxDEV)("div", {
|
|
725
|
+
className: "flex items-baseline justify-between gap-3 min-w-0",
|
|
726
|
+
children: [/* @__PURE__ */ (0, import_jsx_dev_runtime.jsxDEV)("dt", {
|
|
727
|
+
className: "text-[11px] text-sand-500 shrink-0",
|
|
728
|
+
children: info.label
|
|
729
|
+
}, void 0, false, {
|
|
730
|
+
fileName: _jsxFileName$1,
|
|
731
|
+
lineNumber: 472,
|
|
732
|
+
columnNumber: 15
|
|
733
|
+
}, this), /* @__PURE__ */ (0, import_jsx_dev_runtime.jsxDEV)("dd", {
|
|
734
|
+
className: "text-[12px] font-mono text-sand-700 truncate",
|
|
735
|
+
children: info.value
|
|
736
|
+
}, void 0, false, {
|
|
737
|
+
fileName: _jsxFileName$1,
|
|
738
|
+
lineNumber: 473,
|
|
739
|
+
columnNumber: 15
|
|
740
|
+
}, this)]
|
|
741
|
+
}, info.label, true, {
|
|
742
|
+
fileName: _jsxFileName$1,
|
|
743
|
+
lineNumber: 471,
|
|
744
|
+
columnNumber: 13
|
|
745
|
+
}, this))
|
|
746
|
+
}, void 0, false, {
|
|
747
|
+
fileName: _jsxFileName$1,
|
|
748
|
+
lineNumber: 469,
|
|
749
|
+
columnNumber: 9
|
|
750
|
+
}, this)]
|
|
751
|
+
}, void 0, true, {
|
|
752
|
+
fileName: _jsxFileName$1,
|
|
753
|
+
lineNumber: 464,
|
|
754
|
+
columnNumber: 7
|
|
755
|
+
}, this), groups.map((group) => {
|
|
756
|
+
const items = settings.filter((s) => s.group === group);
|
|
757
|
+
return /* @__PURE__ */ (0, import_jsx_dev_runtime.jsxDEV)("div", {
|
|
758
|
+
className: "panel overflow-hidden",
|
|
759
|
+
children: [/* @__PURE__ */ (0, import_jsx_dev_runtime.jsxDEV)("div", {
|
|
760
|
+
className: "panel-header flex items-center justify-between px-4 py-2.5 sm:px-5",
|
|
761
|
+
children: [/* @__PURE__ */ (0, import_jsx_dev_runtime.jsxDEV)("span", {
|
|
762
|
+
className: "text-[13px] font-medium text-sand-700",
|
|
763
|
+
children: GROUP_LABELS.get(group) ?? group
|
|
764
|
+
}, void 0, false, {
|
|
765
|
+
fileName: _jsxFileName$1,
|
|
766
|
+
lineNumber: 485,
|
|
767
|
+
columnNumber: 15
|
|
768
|
+
}, this), group === "slack" && /* @__PURE__ */ (void 0)(TriggerReminderButton, {}, void 0, false, {
|
|
769
|
+
fileName: _jsxFileName$1,
|
|
770
|
+
lineNumber: 488,
|
|
771
|
+
columnNumber: 37
|
|
772
|
+
}, this)]
|
|
773
|
+
}, void 0, true, {
|
|
774
|
+
fileName: _jsxFileName$1,
|
|
775
|
+
lineNumber: 484,
|
|
776
|
+
columnNumber: 13
|
|
777
|
+
}, this), /* @__PURE__ */ (0, import_jsx_dev_runtime.jsxDEV)("div", {
|
|
778
|
+
className: "divide-y divide-sand-100/80",
|
|
779
|
+
children: items.map((item) => /* @__PURE__ */ (0, import_jsx_dev_runtime.jsxDEV)("div", { children: [/* @__PURE__ */ (0, import_jsx_dev_runtime.jsxDEV)(SettingRow, {
|
|
780
|
+
item,
|
|
781
|
+
disabled: item.key === "qgrid.tokenWindowKeepaliveEnabled" && !data?.keepaliveRunnerEnabled
|
|
782
|
+
}, void 0, false, {
|
|
783
|
+
fileName: _jsxFileName$1,
|
|
784
|
+
lineNumber: 493,
|
|
785
|
+
columnNumber: 19
|
|
786
|
+
}, this), item.key === "qgrid.tokenWindowKeepaliveEnabled" && /* @__PURE__ */ (void 0)(KeepaliveTokenSettings, { runnerEnabled: data?.keepaliveRunnerEnabled ?? false }, void 0, false, {
|
|
787
|
+
fileName: _jsxFileName$1,
|
|
788
|
+
lineNumber: 501,
|
|
789
|
+
columnNumber: 21
|
|
790
|
+
}, this)] }, item.key, true, {
|
|
791
|
+
fileName: _jsxFileName$1,
|
|
792
|
+
lineNumber: 492,
|
|
793
|
+
columnNumber: 17
|
|
794
|
+
}, this))
|
|
795
|
+
}, void 0, false, {
|
|
796
|
+
fileName: _jsxFileName$1,
|
|
797
|
+
lineNumber: 490,
|
|
798
|
+
columnNumber: 13
|
|
799
|
+
}, this)]
|
|
800
|
+
}, group, true, {
|
|
801
|
+
fileName: _jsxFileName$1,
|
|
802
|
+
lineNumber: 483,
|
|
803
|
+
columnNumber: 11
|
|
804
|
+
}, this);
|
|
805
|
+
})]
|
|
806
|
+
}, void 0, true, {
|
|
807
|
+
fileName: _jsxFileName$1,
|
|
808
|
+
lineNumber: 463,
|
|
809
|
+
columnNumber: 5
|
|
810
|
+
}, this);
|
|
811
|
+
}
|
|
812
|
+
//#endregion
|
|
813
|
+
//#region src/routes/settings.tsx?tsr-split=component
|
|
814
|
+
var _jsxFileName = "/home/runner/work/qgrid/qgrid/packages/web/src/routes/settings.tsx?tsr-split=component";
|
|
815
|
+
function SettingsPage() {
|
|
816
|
+
return /* @__PURE__ */ (0, import_jsx_dev_runtime.jsxDEV)("div", {
|
|
817
|
+
className: "max-w-4xl mx-auto",
|
|
818
|
+
children: /* @__PURE__ */ (0, import_jsx_dev_runtime.jsxDEV)(SettingsPanel, {}, void 0, false, {
|
|
819
|
+
fileName: _jsxFileName,
|
|
820
|
+
lineNumber: 4,
|
|
821
|
+
columnNumber: 7
|
|
822
|
+
}, this)
|
|
823
|
+
}, void 0, false, {
|
|
824
|
+
fileName: _jsxFileName,
|
|
825
|
+
lineNumber: 3,
|
|
826
|
+
columnNumber: 10
|
|
827
|
+
}, this);
|
|
828
|
+
}
|
|
829
|
+
//#endregion
|
|
830
|
+
export { SettingsPage as component };
|