Skip to content

Commit

Permalink
chore: fix NMS-23504
Browse files Browse the repository at this point in the history
  • Loading branch information
guoxianzhe committed Oct 15, 2024
1 parent 63605c7 commit 33b0a0a
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 10 deletions.
12 changes: 6 additions & 6 deletions example/src/renderer/utils/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -40,12 +40,12 @@ export const arrayToItems = (array: any[]): AgoraDropdownItem[] => {
};

export const enumToItems = (enumType: any): AgoraDropdownItem[] => {
const items = Object.values(enumType);
const keys = items.filter((v) => typeof v === 'string') as string[];
const values = items.filter((v) => typeof v === 'number') as number[];
return keys.map((value, index) => ({
label: value,
value: values[index],
const entries = Object.entries(enumType);
const items = entries.filter(([, value]) => typeof value === 'number');
items.sort((a: any, b: any) => a[1] - b[1]);
return items.map(([key, value]) => ({
label: key,
value: value,
}));
};

Expand Down
8 changes: 4 additions & 4 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -142,9 +142,9 @@
"yuv-canvas": "1.2.6"
},
"agora_electron": {
"iris_sdk_win": "https://download.agora.io/sdk/release/iris_4.5.0-dev.4_DCG_Windows_Video_Standalone_20240927_0549_544.zip",
"iris_sdk_mac": "https://download.agora.io/sdk/release/iris_4.5.0-dev.4_DCG_Mac_Video_Standalone_20240927_0549_505.zip",
"native_sdk_win": "https://download.agora.io/sdk/release/AgoraRtcEngine_windows_Preview_4.5.0-dev.4.zip",
"native_sdk_mac": "https://download.agora.io/sdk/release/AgoraRtcEngine_macOS_Preview_4.5.0-dev.4.zip"
"iris_sdk_win": "https://download.agora.io/sdk/release/iris_4.5.0-dev.6_DCG_Windows_Video_Standalone_20241011_0131_550.zip",
"iris_sdk_mac": "https://download.agora.io/sdk/release/iris_4.5.0-dev.6_DCG_Mac_Video_Standalone_20241011_0131_511.zip",
"native_sdk_win": "https://download.agora.io/sdk/release/AgoraRtcEngine_windows_Preview_4.5.0-dev.6.zip",
"native_sdk_mac": "https://download.agora.io/sdk/release/AgoraRtcEngine_macOS_Preview_4.5.0-dev.6.zip"
}
}

0 comments on commit 33b0a0a

Please sign in to comment.