chore: format all frontend files (#430)
This commit is contained in:
@@ -51,7 +51,7 @@ const getToolGroupText = (key: ToolGroupKey): string =>
|
||||
[ToolGroupKey.DIALOG]: I18n.t('bot_edit_type_dialog'),
|
||||
[ToolGroupKey.CHARACTER]: I18n.t('bot_edit_type_character'),
|
||||
[ToolGroupKey.HOOKS]: 'Hooks',
|
||||
})[key];
|
||||
}[key]);
|
||||
|
||||
const getToolText = (toolKey: ToolKey) =>
|
||||
({
|
||||
@@ -75,7 +75,7 @@ const getToolText = (toolKey: ToolKey) =>
|
||||
[ToolKey.SHORTCUT]: I18n.t('bot_ide_shortcut'),
|
||||
[ToolKey.DEV_HOOKS]: 'Hooks',
|
||||
[ToolKey.USER_INPUT]: I18n.t('chat_setting_user_input_default_mode'),
|
||||
})[toolKey];
|
||||
}[toolKey]);
|
||||
|
||||
const AlertGroups: FC<{ items: AlertItem[] }> = ({ items }) => {
|
||||
const grouped = groupBy(items, 'groupTitle');
|
||||
@@ -296,7 +296,7 @@ const getGroupTittleByConfigType = (type: ModelFuncConfigType): string =>
|
||||
'agentflow_transfer_ conversation_settings_title',
|
||||
),
|
||||
[ModelFuncConfigType.HookInfo]: 'Hooks',
|
||||
})[type];
|
||||
}[type]);
|
||||
|
||||
const getTitleByConfigType = (type: ModelFuncConfigType): string =>
|
||||
// @ts-expect-error fix me late
|
||||
@@ -325,7 +325,7 @@ const getTitleByConfigType = (type: ModelFuncConfigType): string =>
|
||||
'agentflow_transfer_ conversation_settings_mode_node_title',
|
||||
),
|
||||
[ModelFuncConfigType.HookInfo]: 'Hooks',
|
||||
})[type];
|
||||
}[type]);
|
||||
|
||||
export const mapConfigTypeToAlertItem = (
|
||||
type: ModelFuncConfigType,
|
||||
|
||||
@@ -13,7 +13,7 @@
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
|
||||
import { type ReactNode, useState } from 'react';
|
||||
|
||||
import { useRegisteredToolKeyConfigList } from '@coze-agent-ide/tool';
|
||||
|
||||
@@ -13,7 +13,7 @@
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
|
||||
import { type PropsWithChildren, type ReactNode } from 'react';
|
||||
|
||||
import { useField } from '@formily/react';
|
||||
|
||||
@@ -13,7 +13,7 @@
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
|
||||
import {
|
||||
useEffect,
|
||||
useState,
|
||||
|
||||
@@ -13,7 +13,7 @@
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
|
||||
import { useEffect } from 'react';
|
||||
|
||||
import { useCreation } from 'ahooks';
|
||||
|
||||
@@ -13,7 +13,7 @@
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
|
||||
import React, { type CSSProperties } from 'react';
|
||||
|
||||
import { useShallow } from 'zustand/react/shallow';
|
||||
|
||||
@@ -13,7 +13,7 @@
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
|
||||
import React, { useState, type CSSProperties } from 'react';
|
||||
|
||||
import { groupBy } from 'lodash-es';
|
||||
|
||||
@@ -13,7 +13,7 @@
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
|
||||
import { type CSSProperties } from 'react';
|
||||
|
||||
import classNames from 'classnames';
|
||||
|
||||
@@ -13,7 +13,7 @@
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
|
||||
import { type JSXComponent } from '@formily/react';
|
||||
import { InputSlider, type InputSliderProps } from '@coze-studio/components';
|
||||
import {
|
||||
|
||||
@@ -13,7 +13,7 @@
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
|
||||
export { ModelOption, ModelOptionProps } from './model-option';
|
||||
export { ModelOptionGroup, ModelOptionGroupProps } from './model-option-group';
|
||||
export { ModelOptionThumb } from './model-option-thumb';
|
||||
|
||||
@@ -13,7 +13,7 @@
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
|
||||
import { type PropsWithChildren } from 'react';
|
||||
|
||||
import cls from 'classnames';
|
||||
|
||||
@@ -13,7 +13,7 @@
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
|
||||
import { I18n } from '@coze-arch/i18n';
|
||||
import { Avatar, Tag } from '@coze-arch/coze-design';
|
||||
import { type Model } from '@coze-arch/bot-api/developer_api';
|
||||
|
||||
@@ -13,7 +13,7 @@
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
|
||||
import { type ReactNode, useRef, useState } from 'react';
|
||||
|
||||
import { isBoolean } from 'lodash-es';
|
||||
|
||||
@@ -13,7 +13,7 @@
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
|
||||
import { useState } from 'react';
|
||||
|
||||
import { useShallow } from 'zustand/react/shallow';
|
||||
@@ -69,8 +69,8 @@ export function ModelSelect({
|
||||
const canSelectSuperiorModel = isBoolean(canSelectSuperiorModelProps)
|
||||
? canSelectSuperiorModelProps
|
||||
: IS_OVERSEA
|
||||
? !isFree
|
||||
: isBenefitAvailable;
|
||||
? !isFree
|
||||
: isBenefitAvailable;
|
||||
const [upgradeModalState, setUpgradeModalState] = useState<{
|
||||
type?: 'new' | 'advance';
|
||||
visible: boolean;
|
||||
|
||||
@@ -13,7 +13,7 @@
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
|
||||
import { type ReactNode, useEffect, useMemo } from 'react';
|
||||
|
||||
import { omit } from 'lodash-es';
|
||||
|
||||
@@ -13,7 +13,7 @@
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
|
||||
import { type ReactNode, useMemo } from 'react';
|
||||
|
||||
import { groupBy } from 'lodash-es';
|
||||
|
||||
@@ -13,7 +13,7 @@
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
|
||||
import { useMemo, useState } from 'react';
|
||||
|
||||
import { useShallow } from 'zustand/react/shallow';
|
||||
|
||||
@@ -13,7 +13,7 @@
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
|
||||
import { type FC, useMemo, useState } from 'react';
|
||||
|
||||
import { useShallow } from 'zustand/react/shallow';
|
||||
|
||||
Reference in New Issue
Block a user