@logictan/dsh-imagegen 2.0.3 → 2.0.4
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/lib/client.js +120 -122
- package/lib/client.js.map +1 -1
- package/lib/index.js +31 -30
- package/package.json +9 -1
package/lib/client.js
CHANGED
|
@@ -2990,7 +2990,7 @@ window.__ModuleLoader__.load({
|
|
|
2990
2990
|
*/
|
|
2991
2991
|
/** Settings namespace this plugin owns (host settings seam + bridge). */
|
|
2992
2992
|
const IMAGEGEN_SETTINGS_NAMESPACE = "imagegen";
|
|
2993
|
-
/** Same-origin route family (
|
|
2993
|
+
/** Same-origin route family (fenced by the composition's connection service). */
|
|
2994
2994
|
const SETTINGS_API = {
|
|
2995
2995
|
describe: "/api/dsh-imagegen/settings/describe",
|
|
2996
2996
|
mutate: "/api/dsh-imagegen/settings/mutate"
|
|
@@ -3004,7 +3004,7 @@ window.__ModuleLoader__.load({
|
|
|
3004
3004
|
const IMAGE_MODEL_API = { models: "/api/dsh-imagegen/image-models" };
|
|
3005
3005
|
/** Host-served built-in provider catalog (channels the user can instantiate). */
|
|
3006
3006
|
const PRESETS_API = "/api/dsh-imagegen/presets";
|
|
3007
|
-
/**
|
|
3007
|
+
/** Image reader for Agent tool-result previews (fenced by the connection service). */
|
|
3008
3008
|
const AGENT_IMAGE_API = "/api/dsh-imagegen/agent-image";
|
|
3009
3009
|
//#endregion
|
|
3010
3010
|
//#region src/client/use-language.ts
|
|
@@ -3030,132 +3030,132 @@ window.__ModuleLoader__.load({
|
|
|
3030
3030
|
document.head.appendChild(tag);
|
|
3031
3031
|
}
|
|
3032
3032
|
var settings_card_module_css_default = {
|
|
3033
|
-
"
|
|
3034
|
-
"
|
|
3035
|
-
"
|
|
3036
|
-
"
|
|
3037
|
-
"
|
|
3033
|
+
"modelRow": "_5JdLea_modelRow",
|
|
3034
|
+
"overviewHead": "_5JdLea_overviewHead",
|
|
3035
|
+
"versionLabel": "_5JdLea_versionLabel",
|
|
3036
|
+
"reset": "_5JdLea_reset",
|
|
3037
|
+
"summaryCard": "_5JdLea_summaryCard",
|
|
3038
3038
|
"footer": "_5JdLea_footer",
|
|
3039
|
-
"
|
|
3040
|
-
"
|
|
3039
|
+
"channelMeta": "_5JdLea_channelMeta",
|
|
3040
|
+
"channelName": "_5JdLea_channelName",
|
|
3041
|
+
"channelAdd": "_5JdLea_channelAdd",
|
|
3041
3042
|
"subscriptionWarning": "_5JdLea_subscriptionWarning",
|
|
3042
|
-
"
|
|
3043
|
-
"editorSectionHeader": "_5JdLea_editorSectionHeader",
|
|
3044
|
-
"editorBackdrop": "_5JdLea_editorBackdrop",
|
|
3045
|
-
"editorPanel": "_5JdLea_editorPanel",
|
|
3046
|
-
"modelRowInputs": "_5JdLea_modelRowInputs",
|
|
3047
|
-
"channelList": "_5JdLea_channelList",
|
|
3048
|
-
"sectionDivider": "_5JdLea_sectionDivider",
|
|
3049
|
-
"reset": "_5JdLea_reset",
|
|
3050
|
-
"presetHint": "_5JdLea_presetHint",
|
|
3051
|
-
"head": "_5JdLea_head",
|
|
3052
|
-
"invalid": "_5JdLea_invalid",
|
|
3053
|
-
"inlineDisclosure": "_5JdLea_inlineDisclosure",
|
|
3054
|
-
"badges": "_5JdLea_badges",
|
|
3055
|
-
"versionLabel": "_5JdLea_versionLabel",
|
|
3056
|
-
"presetAction": "_5JdLea_presetAction",
|
|
3057
|
-
"sectionContent": "_5JdLea_sectionContent",
|
|
3058
|
-
"notExposed": "_5JdLea_notExposed",
|
|
3059
|
-
"chevronOpen": "_5JdLea_chevronOpen",
|
|
3043
|
+
"manualModelRow": "_5JdLea_manualModelRow",
|
|
3060
3044
|
"modelCandidateList": "_5JdLea_modelCandidateList",
|
|
3061
|
-
"checkboxRow": "_5JdLea_checkboxRow",
|
|
3062
|
-
"pickerDialog": "_5JdLea_pickerDialog",
|
|
3063
|
-
"pickerHint": "_5JdLea_pickerHint",
|
|
3064
|
-
"modelRows": "_5JdLea_modelRows",
|
|
3065
|
-
"pickerList": "_5JdLea_pickerList",
|
|
3066
|
-
"save": "_5JdLea_save",
|
|
3067
|
-
"name": "_5JdLea_name",
|
|
3068
3045
|
"channelMain": "_5JdLea_channelMain",
|
|
3069
|
-
"
|
|
3070
|
-
"
|
|
3071
|
-
"
|
|
3046
|
+
"field": "_5JdLea_field",
|
|
3047
|
+
"header": "_5JdLea_header",
|
|
3048
|
+
"channelDotReady": "_5JdLea_channelDotReady",
|
|
3049
|
+
"presetRow": "_5JdLea_presetRow",
|
|
3072
3050
|
"pickerEmpty": "_5JdLea_pickerEmpty",
|
|
3051
|
+
"editorPanel": "_5JdLea_editorPanel",
|
|
3052
|
+
"pending": "_5JdLea_pending",
|
|
3053
|
+
"name": "_5JdLea_name",
|
|
3054
|
+
"pickerHeader": "_5JdLea_pickerHeader",
|
|
3055
|
+
"editorTools": "_5JdLea_editorTools",
|
|
3056
|
+
"modelRowRemove": "_5JdLea_modelRowRemove",
|
|
3057
|
+
"presetMeta": "_5JdLea_presetMeta",
|
|
3058
|
+
"editorSectionHeader": "_5JdLea_editorSectionHeader",
|
|
3059
|
+
"subscriptionManual": "_5JdLea_subscriptionManual",
|
|
3073
3060
|
"sectionTitle": "_5JdLea_sectionTitle",
|
|
3074
|
-
"
|
|
3075
|
-
"
|
|
3076
|
-
"
|
|
3077
|
-
"summaryCard": "_5JdLea_summaryCard",
|
|
3078
|
-
"label": "_5JdLea_label",
|
|
3079
|
-
"channelAdd": "_5JdLea_channelAdd",
|
|
3080
|
-
"addModel": "_5JdLea_addModel",
|
|
3081
|
-
"channelDotReady": "_5JdLea_channelDotReady",
|
|
3082
|
-
"editorFooter": "_5JdLea_editorFooter",
|
|
3061
|
+
"fieldHint": "_5JdLea_fieldHint",
|
|
3062
|
+
"channelAction": "_5JdLea_channelAction",
|
|
3063
|
+
"channelAddRow": "_5JdLea_channelAddRow",
|
|
3083
3064
|
"inputInvalid": "_5JdLea_inputInvalid",
|
|
3084
|
-
"
|
|
3085
|
-
"
|
|
3086
|
-
"
|
|
3065
|
+
"sectionHeader": "_5JdLea_sectionHeader",
|
|
3066
|
+
"inlineDisclosure": "_5JdLea_inlineDisclosure",
|
|
3067
|
+
"editorBackdrop": "_5JdLea_editorBackdrop",
|
|
3068
|
+
"presetInline": "_5JdLea_presetInline",
|
|
3069
|
+
"versionRow": "_5JdLea_versionRow",
|
|
3087
3070
|
"overviewTitle": "_5JdLea_overviewTitle",
|
|
3088
|
-
"
|
|
3089
|
-
"
|
|
3090
|
-
"
|
|
3091
|
-
"
|
|
3092
|
-
"
|
|
3093
|
-
"
|
|
3094
|
-
"
|
|
3071
|
+
"disclosure": "_5JdLea_disclosure",
|
|
3072
|
+
"invalid": "_5JdLea_invalid",
|
|
3073
|
+
"notExposed": "_5JdLea_notExposed",
|
|
3074
|
+
"modelRows": "_5JdLea_modelRows",
|
|
3075
|
+
"subscriptionDot": "_5JdLea_subscriptionDot",
|
|
3076
|
+
"channelSection": "_5JdLea_channelSection",
|
|
3077
|
+
"versionValue": "_5JdLea_versionValue",
|
|
3078
|
+
"modelSection": "_5JdLea_modelSection",
|
|
3095
3079
|
"settingsSection": "_5JdLea_settingsSection",
|
|
3096
|
-
"
|
|
3097
|
-
"editorTools": "_5JdLea_editorTools",
|
|
3080
|
+
"pickerHint": "_5JdLea_pickerHint",
|
|
3098
3081
|
"hint": "_5JdLea_hint",
|
|
3099
|
-
"
|
|
3100
|
-
"discard": "_5JdLea_discard",
|
|
3101
|
-
"channelName": "_5JdLea_channelName",
|
|
3102
|
-
"channelAddRow": "_5JdLea_channelAddRow",
|
|
3103
|
-
"pending": "_5JdLea_pending",
|
|
3104
|
-
"summaryGrid": "_5JdLea_summaryGrid",
|
|
3105
|
-
"subscriptionBox": "_5JdLea_subscriptionBox",
|
|
3082
|
+
"spacer": "_5JdLea_spacer",
|
|
3106
3083
|
"readOnly": "_5JdLea_readOnly",
|
|
3107
|
-
"
|
|
3108
|
-
"
|
|
3109
|
-
"disclosure": "_5JdLea_disclosure",
|
|
3110
|
-
"badge": "_5JdLea_badge",
|
|
3111
|
-
"modelFetch": "_5JdLea_modelFetch",
|
|
3112
|
-
"modelBadge": "_5JdLea_modelBadge",
|
|
3113
|
-
"modelArrow": "_5JdLea_modelArrow",
|
|
3114
|
-
"channelHost": "_5JdLea_channelHost",
|
|
3115
|
-
"modelChoices": "_5JdLea_modelChoices",
|
|
3116
|
-
"header": "_5JdLea_header",
|
|
3084
|
+
"label": "_5JdLea_label",
|
|
3085
|
+
"detectOk": "_5JdLea_detectOk",
|
|
3117
3086
|
"sectionSummary": "_5JdLea_sectionSummary",
|
|
3118
|
-
"
|
|
3087
|
+
"summaryValue": "_5JdLea_summaryValue",
|
|
3088
|
+
"presetName": "_5JdLea_presetName",
|
|
3089
|
+
"editorHeader": "_5JdLea_editorHeader",
|
|
3090
|
+
"defaultModelRow": "_5JdLea_defaultModelRow",
|
|
3119
3091
|
"headText": "_5JdLea_headText",
|
|
3120
|
-
"
|
|
3121
|
-
"
|
|
3092
|
+
"editorFooter": "_5JdLea_editorFooter",
|
|
3093
|
+
"pickerTitle": "_5JdLea_pickerTitle",
|
|
3094
|
+
"pickerSearch": "_5JdLea_pickerSearch",
|
|
3095
|
+
"pickerDialog": "_5JdLea_pickerDialog",
|
|
3096
|
+
"pickerTabs": "_5JdLea_pickerTabs",
|
|
3097
|
+
"description": "_5JdLea_description",
|
|
3098
|
+
"presetAction": "_5JdLea_presetAction",
|
|
3099
|
+
"summaryLabel": "_5JdLea_summaryLabel",
|
|
3100
|
+
"head": "_5JdLea_head",
|
|
3101
|
+
"channelBadge": "_5JdLea_channelBadge",
|
|
3102
|
+
"overview": "_5JdLea_overview",
|
|
3103
|
+
"sectionDivider": "_5JdLea_sectionDivider",
|
|
3104
|
+
"editorDivider": "_5JdLea_editorDivider",
|
|
3105
|
+
"sectionToggle": "_5JdLea_sectionToggle",
|
|
3106
|
+
"modelRowInputs": "_5JdLea_modelRowInputs",
|
|
3122
3107
|
"subscriptionAccount": "_5JdLea_subscriptionAccount",
|
|
3123
|
-
"
|
|
3124
|
-
"
|
|
3108
|
+
"sectionToggleText": "_5JdLea_sectionToggleText",
|
|
3109
|
+
"editorField": "_5JdLea_editorField",
|
|
3110
|
+
"save": "_5JdLea_save",
|
|
3111
|
+
"card": "_5JdLea_card",
|
|
3112
|
+
"badge": "_5JdLea_badge",
|
|
3125
3113
|
"modelSummary": "_5JdLea_modelSummary",
|
|
3126
|
-
"
|
|
3127
|
-
"
|
|
3128
|
-
"
|
|
3129
|
-
"
|
|
3130
|
-
"
|
|
3131
|
-
"
|
|
3132
|
-
"
|
|
3133
|
-
"
|
|
3114
|
+
"badges": "_5JdLea_badges",
|
|
3115
|
+
"modelRowBadges": "_5JdLea_modelRowBadges",
|
|
3116
|
+
"failed": "_5JdLea_failed",
|
|
3117
|
+
"channelList": "_5JdLea_channelList",
|
|
3118
|
+
"modelFetch": "_5JdLea_modelFetch",
|
|
3119
|
+
"presetHint": "_5JdLea_presetHint",
|
|
3120
|
+
"checkboxRow": "_5JdLea_checkboxRow",
|
|
3121
|
+
"sectionToggleTitle": "_5JdLea_sectionToggleTitle",
|
|
3122
|
+
"deleteConfirmText": "_5JdLea_deleteConfirmText",
|
|
3123
|
+
"presetList": "_5JdLea_presetList",
|
|
3134
3124
|
"channelControls": "_5JdLea_channelControls",
|
|
3135
|
-
"
|
|
3136
|
-
"field": "_5JdLea_field",
|
|
3125
|
+
"discard": "_5JdLea_discard",
|
|
3137
3126
|
"channelDanger": "_5JdLea_channelDanger",
|
|
3138
|
-
"
|
|
3139
|
-
"
|
|
3140
|
-
"
|
|
3141
|
-
"
|
|
3127
|
+
"healthBadge": "_5JdLea_healthBadge",
|
|
3128
|
+
"textareaInvalid": "_5JdLea_textareaInvalid",
|
|
3129
|
+
"chevron": "_5JdLea_chevron",
|
|
3130
|
+
"sectionContent": "_5JdLea_sectionContent",
|
|
3142
3131
|
"presetInlineHeader": "_5JdLea_presetInlineHeader",
|
|
3143
|
-
"pickerTitle": "_5JdLea_pickerTitle",
|
|
3144
|
-
"sectionChevron": "_5JdLea_sectionChevron",
|
|
3145
3132
|
"modelCandidate": "_5JdLea_modelCandidate",
|
|
3146
|
-
"
|
|
3147
|
-
"
|
|
3148
|
-
"
|
|
3149
|
-
"
|
|
3150
|
-
"
|
|
3151
|
-
"
|
|
3152
|
-
"
|
|
3153
|
-
"
|
|
3154
|
-
"
|
|
3155
|
-
"
|
|
3156
|
-
"
|
|
3157
|
-
"
|
|
3158
|
-
"
|
|
3133
|
+
"subscriptionBox": "_5JdLea_subscriptionBox",
|
|
3134
|
+
"optionalContent": "_5JdLea_optionalContent",
|
|
3135
|
+
"sectionHint": "_5JdLea_sectionHint",
|
|
3136
|
+
"channelEmpty": "_5JdLea_channelEmpty",
|
|
3137
|
+
"channelDotWarn": "_5JdLea_channelDotWarn",
|
|
3138
|
+
"modelChoices": "_5JdLea_modelChoices",
|
|
3139
|
+
"channelRow": "_5JdLea_channelRow",
|
|
3140
|
+
"pickerOverlay": "_5JdLea_pickerOverlay",
|
|
3141
|
+
"select": "_5JdLea_select",
|
|
3142
|
+
"modelBadge": "_5JdLea_modelBadge",
|
|
3143
|
+
"overviewHint": "_5JdLea_overviewHint",
|
|
3144
|
+
"pickerList": "_5JdLea_pickerList",
|
|
3145
|
+
"sectionChevron": "_5JdLea_sectionChevron",
|
|
3146
|
+
"modelFetchRow": "_5JdLea_modelFetchRow",
|
|
3147
|
+
"body": "_5JdLea_body",
|
|
3148
|
+
"modelChip": "_5JdLea_modelChip",
|
|
3149
|
+
"editorClose": "_5JdLea_editorClose",
|
|
3150
|
+
"chevronOpen": "_5JdLea_chevronOpen",
|
|
3151
|
+
"textarea": "_5JdLea_textarea",
|
|
3152
|
+
"addModel": "_5JdLea_addModel",
|
|
3153
|
+
"modelCandidateLabel": "_5JdLea_modelCandidateLabel",
|
|
3154
|
+
"summaryGrid": "_5JdLea_summaryGrid",
|
|
3155
|
+
"input": "_5JdLea_input",
|
|
3156
|
+
"channelHost": "_5JdLea_channelHost",
|
|
3157
|
+
"modelArrow": "_5JdLea_modelArrow",
|
|
3158
|
+
"sectionToggleHint": "_5JdLea_sectionToggleHint"
|
|
3159
3159
|
};
|
|
3160
3160
|
//#endregion
|
|
3161
3161
|
//#region src/client/SettingsCard.tsx
|
|
@@ -4395,11 +4395,11 @@ window.__ModuleLoader__.load({
|
|
|
4395
4395
|
//#region src/client/settings-scope.ts
|
|
4396
4396
|
/**
|
|
4397
4397
|
* Browser-side settings scope for the dsh-imagegen namespace, served by the
|
|
4398
|
-
* plugin's own
|
|
4398
|
+
* plugin's own same-origin bridge routes (/api/dsh-imagegen/settings). The
|
|
4399
4399
|
* official rc.6 settings scope answers "unavailable" for every third-party
|
|
4400
4400
|
* namespace (the host-apiproxy allowlist is hard-coded), so this package
|
|
4401
|
-
* re-serves its namespace through the host settings seam over a same-origin
|
|
4402
|
-
*
|
|
4401
|
+
* re-serves its namespace through the host settings seam over a same-origin
|
|
4402
|
+
* HTTP pair — the same pattern the dsh-web-ui family bridge
|
|
4403
4403
|
* uses, self-contained per plugin.
|
|
4404
4404
|
*/
|
|
4405
4405
|
/** Settings wire face over the bridge routes (fetch-backed). */
|
|
@@ -4587,7 +4587,7 @@ window.__ModuleLoader__.load({
|
|
|
4587
4587
|
/**
|
|
4588
4588
|
* Bind the dsh-imagegen settings scope over the bridge routes and start its
|
|
4589
4589
|
* initial read (the caller mounts nothing until the scope settles).
|
|
4590
|
-
* @param fetchFn - the fetch implementation (the global fetch
|
|
4590
|
+
* @param fetchFn - the fetch implementation (the global fetch by default).
|
|
4591
4591
|
* @returns the scope; unavailable when the bridge is unreachable.
|
|
4592
4592
|
*/
|
|
4593
4593
|
function bindImageGenScope(fetchFn = fetch) {
|
|
@@ -4607,16 +4607,16 @@ window.__ModuleLoader__.load({
|
|
|
4607
4607
|
document.head.appendChild(tag);
|
|
4608
4608
|
}
|
|
4609
4609
|
var image_toolview_module_css_default = {
|
|
4610
|
-
"
|
|
4610
|
+
"root": "UtJPoq_root",
|
|
4611
|
+
"header": "UtJPoq_header",
|
|
4612
|
+
"icon": "UtJPoq_icon",
|
|
4613
|
+
"error": "UtJPoq_error",
|
|
4611
4614
|
"status": "UtJPoq_status",
|
|
4612
4615
|
"message": "UtJPoq_message",
|
|
4613
|
-
"error": "UtJPoq_error",
|
|
4614
4616
|
"images": "UtJPoq_images",
|
|
4615
|
-
"
|
|
4616
|
-
"loading": "UtJPoq_loading",
|
|
4617
|
-
"root": "UtJPoq_root",
|
|
4617
|
+
"imageLink": "UtJPoq_imageLink",
|
|
4618
4618
|
"image": "UtJPoq_image",
|
|
4619
|
-
"
|
|
4619
|
+
"loading": "UtJPoq_loading"
|
|
4620
4620
|
};
|
|
4621
4621
|
//#endregion
|
|
4622
4622
|
//#region src/client/image-toolview.tsx
|
|
@@ -4847,9 +4847,7 @@ window.__ModuleLoader__.load({
|
|
|
4847
4847
|
return ctx.locale.subscribe(applyLocale);
|
|
4848
4848
|
}, "dsh-imagegen: follow host locale");
|
|
4849
4849
|
registerImageToolviews(ctx);
|
|
4850
|
-
const scope = bindImageGenScope(
|
|
4851
|
-
throw new Error("settings bridge is loopback-only");
|
|
4852
|
-
});
|
|
4850
|
+
const scope = bindImageGenScope();
|
|
4853
4851
|
ctx.effect(() => {
|
|
4854
4852
|
const disposers = [ctx.on("connection/reset", () => {
|
|
4855
4853
|
scope.load();
|