decord/source/modules/interaction_components/StringSelectActionComponentUtils.tsx

28 lines
1.1 KiB
TypeScript
Raw Normal View History

2026-07-25 08:10:48 +00:00
// Module ID: 7839
2026-07-27 11:26:19 +00:00
// Function ID: 62572
2026-07-20 16:05:17 +00:00
// Name: getInitialStringSelectOptions
2026-07-25 08:10:48 +00:00
// Dependencies: [7833, 1882, 2]
2026-07-20 16:05:17 +00:00
// Exports: getInitialStringSelectOptions
2026-07-25 08:10:48 +00:00
// Module 7839 (getInitialStringSelectOptions)
2026-07-23 10:11:24 +00:00
import _isNativeReflectConstruct from "_isNativeReflectConstruct";
const require = arg1;
const result = require("set").fileFinishedImporting("modules/interaction_components/StringSelectActionComponentUtils.tsx");
2026-07-20 16:05:17 +00:00
export const getInitialStringSelectOptions = function getInitialStringSelectOptions(selectionActionComponent, containerId) {
2026-07-23 10:11:24 +00:00
interactionComponentState = interactionComponentState.getInteractionComponentState(containerId, selectionActionComponent.id);
2026-07-20 16:05:17 +00:00
let type;
if (null != interactionComponentState) {
type = interactionComponentState.type;
}
2026-07-25 08:10:48 +00:00
if (type === require(1882) /* PermissionOverwriteType */.ComponentType.STRING_SELECT) {
2026-07-20 16:05:17 +00:00
let mapped = interactionComponentState.values;
} else {
const options = selectionActionComponent.options;
const found = options.filter((arg0) => arg0.default);
mapped = found.map((value) => value.value);
}
return mapped;
};