dsh-tokenbank 0.1.41 → 0.1.43
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 +6 -6
- package/package.json +1 -1
package/lib/client.js
CHANGED
|
@@ -576,10 +576,10 @@ window.__ModuleLoader__.load({
|
|
|
576
576
|
var relayTokens = (cny / 7.8) / usdOfPack * tbTokens // 中转站 $1≈¥7.8
|
|
577
577
|
return [
|
|
578
578
|
h('div', { style: { display: 'flex', justifyContent: 'space-between', alignItems: 'center' } },
|
|
579
|
-
h('span', { style: { fontWeight: 700 } }, 'TokenBank'),
|
|
580
579
|
h('span', { style: { display: 'flex', alignItems: 'center', gap: 4 } },
|
|
581
|
-
h('span', { style: {
|
|
582
|
-
|
|
580
|
+
h('span', { style: { fontWeight: 700 } }, 'TokenBank'),
|
|
581
|
+
h('span', { style: { background: '#ff4f1f', color: '#fff', borderRadius: 4, padding: '1px 5px', fontSize: 11, fontWeight: 700 } }, '最优惠')),
|
|
582
|
+
h('span', null, humanTokens(tbTokens) + ' TOKEN')),
|
|
583
583
|
h('div', { style: { display: 'flex', justifyContent: 'space-between' } },
|
|
584
584
|
h('span', null, 'OpenAI/Anthropic 等'),
|
|
585
585
|
h('span', null, humanTokens(vendorTokens) + ' TOKEN')),
|
|
@@ -753,7 +753,7 @@ window.__ModuleLoader__.load({
|
|
|
753
753
|
},
|
|
754
754
|
h('span', { style: { color: innerToast[0].error ? '#d03050' : '#22a04a', fontWeight: 700 } }, innerToast[0].error ? '✕' : '✓'),
|
|
755
755
|
h('span', { style: { flex: 1 } }, innerToast[0].text),
|
|
756
|
-
innerToast[0].error
|
|
756
|
+
(!innerToast[0].error && innerToast[0].kind === 'models') ? h('button', {
|
|
757
757
|
type: 'button', style: Object.assign({}, buttonStyle, { height: 24, padding: '0 10px', fontSize: 12 }),
|
|
758
758
|
onClick: function () {
|
|
759
759
|
innerToast[1](null)
|
|
@@ -766,7 +766,7 @@ window.__ModuleLoader__.load({
|
|
|
766
766
|
}
|
|
767
767
|
}, 80)
|
|
768
768
|
},
|
|
769
|
-
}, pageT('goSwitch')),
|
|
769
|
+
}, pageT('goSwitch')) : null,
|
|
770
770
|
) : !rechargeOpen[0] ? h('button', {
|
|
771
771
|
type: 'button', style: Object.assign({}, primaryButtonStyle, { justifyContent: 'center' }),
|
|
772
772
|
onClick: async function () {
|
|
@@ -774,7 +774,7 @@ window.__ModuleLoader__.load({
|
|
|
774
774
|
var models = await api('gateway-models', { accessKey: data.accessKey })
|
|
775
775
|
var list = Array.isArray(models) ? models : (models.models || models.list || [])
|
|
776
776
|
await addProviderToModels(runtimeCtx, data.baseURL || portal, { accessKey: data.accessKey, list: list, protocol: models.protocol })
|
|
777
|
-
innerToast[1]({ text: pageT('modelListCount').replace('{n}', String(list.length)) })
|
|
777
|
+
innerToast[1]({ kind: 'models', text: pageT('modelListCount').replace('{n}', String(list.length)) })
|
|
778
778
|
} catch (err) {
|
|
779
779
|
tbStore.set({ notify: { kind: 'error', title: String(err.message || err), detail: '' } })
|
|
780
780
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "dsh-tokenbank",
|
|
3
|
-
"version": "0.1.
|
|
3
|
+
"version": "0.1.43",
|
|
4
4
|
"description": "DSH 免费模型:一键注册 TokenBank 领免费 APIKey 送 $5 体验金,免费 GLM 模型直接进模型列表;自带余额查询、API Key 密钥托管(临时额度转永久)、每日签到、充值入口(支付宝),获取免费模型无需自建中转。致敬 dsh-our-free-model。官网 https://bank.skillpie.cn",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"license": "MIT",
|