@logictan/dsh-imagegen 2.0.1 → 2.0.3

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 CHANGED
@@ -46,7 +46,7 @@ dsh plugin --profile web add @logictan/dsh-imagegen
46
46
  | --- | --- |
47
47
  | 预设 | 常见厂商的预填(OpenAI 官方、xAI Grok Imagine、Google Nano Banana、字节 Seedream、智谱 GLM-Image、阿里 Qwen-Image、MiniMax image-01 等) |
48
48
  | API 地址 | 该渠道的端点;非 OpenAI 兼容协议的厂商按其官方接口填写(预设里已说明) |
49
- | API 密钥 | 仅存于本机设置文档,生成时由宿主代理转发 |
49
+ | API 密钥 | 凭据,存于 `$DSH_HOME/.credentials.yaml`(渠道密钥为 `DSH_IMAGEGEN_CHANNEL_<渠道 ID>`,提示词增强为 `DSH_IMAGEGEN_PROMPT_KEY`);不写入插件配置行,生成时由宿主代理转发 |
50
50
  | 模型目录 | 该渠道下可用的「别名 → 上游模型 id」映射 |
51
51
 
52
52
  可选配置**提示词增强**:填一个 OpenAI 兼容的聊天端点与模型,生图前会把简短提示词扩写成更完整的描述。
package/lib/client.js CHANGED
@@ -2583,9 +2583,11 @@ window.__ModuleLoader__.load({
2583
2583
  *
2584
2584
  * Storage rules (dictated by dsh-settings semantics):
2585
2585
  * - the whole `channels` array is written wholesale via `path: ['channels']`;
2586
- * - every channel's API key lives at `channelSecrets.<channelId>` (a secret
2587
- * dict), written per-key so untouched keys are never clobbered by a save
2588
- * the reader could not see (keys are redacted out of the wire view);
2586
+ * - every channel's API key is written to `path: ['channelSecrets', <id>]`,
2587
+ * one key at a time so untouched keys are never clobbered by a save the
2588
+ * reader could not see (keys are redacted out of the wire view). The host
2589
+ * bridge diverts that path into the credential store, so the value never
2590
+ * reaches the settings document — this module only speaks the wire shape;
2589
2591
  * - path ops never navigate *inside* the channels array.
2590
2592
  */
2591
2593
  /** Deep equality over JSON-compatible data (the change predicate). */
@@ -3028,132 +3030,132 @@ window.__ModuleLoader__.load({
3028
3030
  document.head.appendChild(tag);
3029
3031
  }
3030
3032
  var settings_card_module_css_default = {
3031
- "chevronOpen": "_5JdLea_chevronOpen",
3032
- "field": "_5JdLea_field",
3033
- "modelSection": "_5JdLea_modelSection",
3033
+ "textareaInvalid": "_5JdLea_textareaInvalid",
3034
+ "healthBadge": "_5JdLea_healthBadge",
3035
+ "pickerHeader": "_5JdLea_pickerHeader",
3036
+ "overviewHint": "_5JdLea_overviewHint",
3037
+ "modelChip": "_5JdLea_modelChip",
3038
+ "footer": "_5JdLea_footer",
3034
3039
  "failed": "_5JdLea_failed",
3035
- "select": "_5JdLea_select",
3036
- "chevron": "_5JdLea_chevron",
3037
- "fieldHint": "_5JdLea_fieldHint",
3040
+ "pickerOverlay": "_5JdLea_pickerOverlay",
3041
+ "subscriptionWarning": "_5JdLea_subscriptionWarning",
3038
3042
  "sectionToggleText": "_5JdLea_sectionToggleText",
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",
3039
3057
  "sectionContent": "_5JdLea_sectionContent",
3040
- "subscriptionAccount": "_5JdLea_subscriptionAccount",
3041
- "channelSection": "_5JdLea_channelSection",
3042
- "channelBadge": "_5JdLea_channelBadge",
3043
- "summaryCard": "_5JdLea_summaryCard",
3044
- "channelDotReady": "_5JdLea_channelDotReady",
3045
- "presetRow": "_5JdLea_presetRow",
3058
+ "notExposed": "_5JdLea_notExposed",
3059
+ "chevronOpen": "_5JdLea_chevronOpen",
3046
3060
  "modelCandidateList": "_5JdLea_modelCandidateList",
3047
- "sectionHint": "_5JdLea_sectionHint",
3048
- "addModel": "_5JdLea_addModel",
3049
- "pickerSearch": "_5JdLea_pickerSearch",
3050
- "modelChoices": "_5JdLea_modelChoices",
3051
- "modelRowBadges": "_5JdLea_modelRowBadges",
3061
+ "checkboxRow": "_5JdLea_checkboxRow",
3062
+ "pickerDialog": "_5JdLea_pickerDialog",
3063
+ "pickerHint": "_5JdLea_pickerHint",
3064
+ "modelRows": "_5JdLea_modelRows",
3065
+ "pickerList": "_5JdLea_pickerList",
3066
+ "save": "_5JdLea_save",
3052
3067
  "name": "_5JdLea_name",
3053
- "badges": "_5JdLea_badges",
3054
- "channelRow": "_5JdLea_channelRow",
3055
- "headText": "_5JdLea_headText",
3056
- "sectionToggle": "_5JdLea_sectionToggle",
3057
- "overview": "_5JdLea_overview",
3058
- "channelList": "_5JdLea_channelList",
3059
- "editorPanel": "_5JdLea_editorPanel",
3060
- "editorHeader": "_5JdLea_editorHeader",
3061
- "editorDivider": "_5JdLea_editorDivider",
3062
- "summaryValue": "_5JdLea_summaryValue",
3063
- "channelMeta": "_5JdLea_channelMeta",
3068
+ "channelMain": "_5JdLea_channelMain",
3069
+ "versionRow": "_5JdLea_versionRow",
3070
+ "manualModelRow": "_5JdLea_manualModelRow",
3071
+ "presetList": "_5JdLea_presetList",
3064
3072
  "pickerEmpty": "_5JdLea_pickerEmpty",
3065
- "subscriptionManual": "_5JdLea_subscriptionManual",
3066
- "discard": "_5JdLea_discard",
3067
- "card": "_5JdLea_card",
3068
- "editorBackdrop": "_5JdLea_editorBackdrop",
3069
- "presetInline": "_5JdLea_presetInline",
3070
- "presetName": "_5JdLea_presetName",
3073
+ "sectionTitle": "_5JdLea_sectionTitle",
3074
+ "modelRowBadges": "_5JdLea_modelRowBadges",
3075
+ "modelSection": "_5JdLea_modelSection",
3076
+ "sectionHeader": "_5JdLea_sectionHeader",
3077
+ "summaryCard": "_5JdLea_summaryCard",
3078
+ "label": "_5JdLea_label",
3079
+ "channelAdd": "_5JdLea_channelAdd",
3080
+ "addModel": "_5JdLea_addModel",
3081
+ "channelDotReady": "_5JdLea_channelDotReady",
3082
+ "editorFooter": "_5JdLea_editorFooter",
3083
+ "inputInvalid": "_5JdLea_inputInvalid",
3084
+ "textarea": "_5JdLea_textarea",
3085
+ "channelBadge": "_5JdLea_channelBadge",
3086
+ "channelDotWarn": "_5JdLea_channelDotWarn",
3087
+ "overviewTitle": "_5JdLea_overviewTitle",
3088
+ "optionalContent": "_5JdLea_optionalContent",
3089
+ "summaryValue": "_5JdLea_summaryValue",
3071
3090
  "sectionToggleTitle": "_5JdLea_sectionToggleTitle",
3072
- "disclosure": "_5JdLea_disclosure",
3073
- "subscriptionWarning": "_5JdLea_subscriptionWarning",
3074
- "modelFetchRow": "_5JdLea_modelFetchRow",
3075
- "spacer": "_5JdLea_spacer",
3076
- "channelEmpty": "_5JdLea_channelEmpty",
3091
+ "presetName": "_5JdLea_presetName",
3077
3092
  "summaryLabel": "_5JdLea_summaryLabel",
3093
+ "editorClose": "_5JdLea_editorClose",
3094
+ "body": "_5JdLea_body",
3095
+ "settingsSection": "_5JdLea_settingsSection",
3096
+ "sectionToggle": "_5JdLea_sectionToggle",
3097
+ "editorTools": "_5JdLea_editorTools",
3098
+ "hint": "_5JdLea_hint",
3099
+ "input": "_5JdLea_input",
3100
+ "discard": "_5JdLea_discard",
3078
3101
  "channelName": "_5JdLea_channelName",
3079
- "modelRowInputs": "_5JdLea_modelRowInputs",
3102
+ "channelAddRow": "_5JdLea_channelAddRow",
3103
+ "pending": "_5JdLea_pending",
3080
3104
  "summaryGrid": "_5JdLea_summaryGrid",
3081
- "invalid": "_5JdLea_invalid",
3082
- "sectionSummary": "_5JdLea_sectionSummary",
3083
- "pickerHint": "_5JdLea_pickerHint",
3084
- "modelRow": "_5JdLea_modelRow",
3085
- "editorField": "_5JdLea_editorField",
3105
+ "subscriptionBox": "_5JdLea_subscriptionBox",
3106
+ "readOnly": "_5JdLea_readOnly",
3107
+ "channelRow": "_5JdLea_channelRow",
3108
+ "presetMeta": "_5JdLea_presetMeta",
3109
+ "disclosure": "_5JdLea_disclosure",
3110
+ "badge": "_5JdLea_badge",
3111
+ "modelFetch": "_5JdLea_modelFetch",
3112
+ "modelBadge": "_5JdLea_modelBadge",
3113
+ "modelArrow": "_5JdLea_modelArrow",
3086
3114
  "channelHost": "_5JdLea_channelHost",
3087
- "pickerOverlay": "_5JdLea_pickerOverlay",
3088
- "overviewHint": "_5JdLea_overviewHint",
3089
- "sectionDivider": "_5JdLea_sectionDivider",
3090
- "defaultModelRow": "_5JdLea_defaultModelRow",
3091
- "textareaInvalid": "_5JdLea_textareaInvalid",
3092
- "modelCandidate": "_5JdLea_modelCandidate",
3093
- "channelAction": "_5JdLea_channelAction",
3094
- "editorFooter": "_5JdLea_editorFooter",
3095
- "overviewHead": "_5JdLea_overviewHead",
3096
- "pickerHeader": "_5JdLea_pickerHeader",
3097
- "manualModelRow": "_5JdLea_manualModelRow",
3098
- "sectionChevron": "_5JdLea_sectionChevron",
3099
- "checkboxRow": "_5JdLea_checkboxRow",
3100
- "editorTools": "_5JdLea_editorTools",
3115
+ "modelChoices": "_5JdLea_modelChoices",
3116
+ "header": "_5JdLea_header",
3117
+ "sectionSummary": "_5JdLea_sectionSummary",
3118
+ "presetRow": "_5JdLea_presetRow",
3119
+ "headText": "_5JdLea_headText",
3120
+ "versionValue": "_5JdLea_versionValue",
3121
+ "subscriptionDot": "_5JdLea_subscriptionDot",
3122
+ "subscriptionAccount": "_5JdLea_subscriptionAccount",
3123
+ "presetInline": "_5JdLea_presetInline",
3124
+ "channelEmpty": "_5JdLea_channelEmpty",
3125
+ "modelSummary": "_5JdLea_modelSummary",
3101
3126
  "sectionToggleHint": "_5JdLea_sectionToggleHint",
3127
+ "chevron": "_5JdLea_chevron",
3128
+ "modelFetchRow": "_5JdLea_modelFetchRow",
3129
+ "channelSection": "_5JdLea_channelSection",
3130
+ "editorDivider": "_5JdLea_editorDivider",
3131
+ "overview": "_5JdLea_overview",
3132
+ "pickerSearch": "_5JdLea_pickerSearch",
3133
+ "select": "_5JdLea_select",
3134
+ "channelControls": "_5JdLea_channelControls",
3135
+ "description": "_5JdLea_description",
3136
+ "field": "_5JdLea_field",
3102
3137
  "channelDanger": "_5JdLea_channelDanger",
3103
- "sectionTitle": "_5JdLea_sectionTitle",
3104
- "editorSectionHeader": "_5JdLea_editorSectionHeader",
3105
- "channelDotWarn": "_5JdLea_channelDotWarn",
3106
- "modelChip": "_5JdLea_modelChip",
3138
+ "sectionHint": "_5JdLea_sectionHint",
3107
3139
  "modelCandidateLabel": "_5JdLea_modelCandidateLabel",
3108
- "footer": "_5JdLea_footer",
3109
- "body": "_5JdLea_body",
3110
- "description": "_5JdLea_description",
3111
- "editorClose": "_5JdLea_editorClose",
3112
- "versionLabel": "_5JdLea_versionLabel",
3113
- "versionRow": "_5JdLea_versionRow",
3114
- "versionValue": "_5JdLea_versionValue",
3115
- "channelControls": "_5JdLea_channelControls",
3116
- "readOnly": "_5JdLea_readOnly",
3117
- "subscriptionBox": "_5JdLea_subscriptionBox",
3118
- "modelRowRemove": "_5JdLea_modelRowRemove",
3119
- "label": "_5JdLea_label",
3120
- "modelBadge": "_5JdLea_modelBadge",
3121
- "head": "_5JdLea_head",
3122
- "optionalContent": "_5JdLea_optionalContent",
3123
- "channelAddRow": "_5JdLea_channelAddRow",
3124
- "sectionHeader": "_5JdLea_sectionHeader",
3125
- "presetMeta": "_5JdLea_presetMeta",
3126
- "healthBadge": "_5JdLea_healthBadge",
3127
- "presetAction": "_5JdLea_presetAction",
3128
- "detectOk": "_5JdLea_detectOk",
3129
- "inputInvalid": "_5JdLea_inputInvalid",
3130
3140
  "deleteConfirmText": "_5JdLea_deleteConfirmText",
3131
- "input": "_5JdLea_input",
3132
- "overviewTitle": "_5JdLea_overviewTitle",
3141
+ "editorHeader": "_5JdLea_editorHeader",
3142
+ "presetInlineHeader": "_5JdLea_presetInlineHeader",
3133
3143
  "pickerTitle": "_5JdLea_pickerTitle",
3134
- "subscriptionDot": "_5JdLea_subscriptionDot",
3144
+ "sectionChevron": "_5JdLea_sectionChevron",
3145
+ "modelCandidate": "_5JdLea_modelCandidate",
3146
+ "detectOk": "_5JdLea_detectOk",
3147
+ "channelAction": "_5JdLea_channelAction",
3148
+ "defaultModelRow": "_5JdLea_defaultModelRow",
3149
+ "spacer": "_5JdLea_spacer",
3150
+ "editorField": "_5JdLea_editorField",
3151
+ "modelRow": "_5JdLea_modelRow",
3135
3152
  "pickerTabs": "_5JdLea_pickerTabs",
3136
- "hint": "_5JdLea_hint",
3137
- "presetHint": "_5JdLea_presetHint",
3138
- "settingsSection": "_5JdLea_settingsSection",
3139
- "notExposed": "_5JdLea_notExposed",
3140
- "header": "_5JdLea_header",
3141
- "save": "_5JdLea_save",
3142
- "reset": "_5JdLea_reset",
3143
- "presetInlineHeader": "_5JdLea_presetInlineHeader",
3144
- "modelFetch": "_5JdLea_modelFetch",
3145
- "pickerDialog": "_5JdLea_pickerDialog",
3146
- "modelArrow": "_5JdLea_modelArrow",
3147
- "modelSummary": "_5JdLea_modelSummary",
3148
- "inlineDisclosure": "_5JdLea_inlineDisclosure",
3149
- "pickerList": "_5JdLea_pickerList",
3150
- "pending": "_5JdLea_pending",
3151
- "channelAdd": "_5JdLea_channelAdd",
3152
- "badge": "_5JdLea_badge",
3153
- "textarea": "_5JdLea_textarea",
3154
- "modelRows": "_5JdLea_modelRows",
3155
- "channelMain": "_5JdLea_channelMain",
3156
- "presetList": "_5JdLea_presetList"
3153
+ "subscriptionManual": "_5JdLea_subscriptionManual",
3154
+ "overviewHead": "_5JdLea_overviewHead",
3155
+ "channelMeta": "_5JdLea_channelMeta",
3156
+ "fieldHint": "_5JdLea_fieldHint",
3157
+ "card": "_5JdLea_card",
3158
+ "modelRowRemove": "_5JdLea_modelRowRemove"
3157
3159
  };
3158
3160
  //#endregion
3159
3161
  //#region src/client/SettingsCard.tsx
@@ -4605,16 +4607,16 @@ window.__ModuleLoader__.load({
4605
4607
  document.head.appendChild(tag);
4606
4608
  }
4607
4609
  var image_toolview_module_css_default = {
4608
- "header": "UtJPoq_header",
4609
- "images": "UtJPoq_images",
4610
4610
  "imageLink": "UtJPoq_imageLink",
4611
+ "status": "UtJPoq_status",
4612
+ "message": "UtJPoq_message",
4611
4613
  "error": "UtJPoq_error",
4614
+ "images": "UtJPoq_images",
4612
4615
  "icon": "UtJPoq_icon",
4613
- "message": "UtJPoq_message",
4614
- "status": "UtJPoq_status",
4615
- "root": "UtJPoq_root",
4616
4616
  "loading": "UtJPoq_loading",
4617
- "image": "UtJPoq_image"
4617
+ "root": "UtJPoq_root",
4618
+ "image": "UtJPoq_image",
4619
+ "header": "UtJPoq_header"
4618
4620
  };
4619
4621
  //#endregion
4620
4622
  //#region src/client/image-toolview.tsx