For @nadr0
This commit is contained in:
@ -150,6 +150,7 @@ export type ModelingCommandSchema = {
|
|||||||
namedValue: KclCommandValue
|
namedValue: KclCommandValue
|
||||||
}
|
}
|
||||||
'Prompt-to-edit': {
|
'Prompt-to-edit': {
|
||||||
|
projectEntrypoint: string
|
||||||
prompt: string
|
prompt: string
|
||||||
selection: Selections
|
selection: Selections
|
||||||
}
|
}
|
||||||
@ -946,6 +947,12 @@ export const modelingMachineCommandConfig: StateMachineCommandSetConfig<
|
|||||||
icon: 'chat',
|
icon: 'chat',
|
||||||
status: IS_ML_EXPERIMENTAL ? 'experimental' : 'active',
|
status: IS_ML_EXPERIMENTAL ? 'experimental' : 'active',
|
||||||
args: {
|
args: {
|
||||||
|
projectEntrypoint: {
|
||||||
|
defaultValue: (argsToSubmit, modelingMachine, fileMachineContext) =>
|
||||||
|
false, //fileMachineContext.currentProject,
|
||||||
|
hidden: () => false, //!contains"main.kcl",
|
||||||
|
required: true,
|
||||||
|
},
|
||||||
selection: {
|
selection: {
|
||||||
inputType: 'selectionMixed',
|
inputType: 'selectionMixed',
|
||||||
selectionTypes: [
|
selectionTypes: [
|
||||||
|
|||||||
@ -13,6 +13,7 @@ import type {
|
|||||||
CommandBarContext,
|
CommandBarContext,
|
||||||
commandBarMachine,
|
commandBarMachine,
|
||||||
} from '@src/machines/commandBarMachine'
|
} from '@src/machines/commandBarMachine'
|
||||||
|
import type { fileMachine } from '@src/machines/fileMachine'
|
||||||
|
|
||||||
type Icon = CustomIconName
|
type Icon = CustomIconName
|
||||||
const _PLATFORMS = ['both', 'web', 'desktop'] as const
|
const _PLATFORMS = ['both', 'web', 'desktop'] as const
|
||||||
@ -144,7 +145,8 @@ export type CommandArgumentConfig<
|
|||||||
| boolean
|
| boolean
|
||||||
| ((
|
| ((
|
||||||
commandBarContext: { argumentsToSubmit: Record<string, unknown> }, // Should be the commandbarMachine's context, but it creates a circular dependency
|
commandBarContext: { argumentsToSubmit: Record<string, unknown> }, // Should be the commandbarMachine's context, but it creates a circular dependency
|
||||||
machineContext?: C
|
machineContext?: C,
|
||||||
|
fileMachineContext?: ContextFrom<typeof fileMachine>
|
||||||
) => boolean)
|
) => boolean)
|
||||||
skip?: boolean
|
skip?: boolean
|
||||||
/** For showing a summary display of the current value, such as in
|
/** For showing a summary display of the current value, such as in
|
||||||
@ -168,7 +170,8 @@ export type CommandArgumentConfig<
|
|||||||
| OutputType
|
| OutputType
|
||||||
| ((
|
| ((
|
||||||
commandBarContext: ContextFrom<typeof commandBarMachine>,
|
commandBarContext: ContextFrom<typeof commandBarMachine>,
|
||||||
machineContext?: C
|
machineContext?: C,
|
||||||
|
fileMachineContext?: ContextFrom<typeof fileMachine>
|
||||||
) => OutputType)
|
) => OutputType)
|
||||||
defaultValueFromContext?: (context: C) => OutputType
|
defaultValueFromContext?: (context: C) => OutputType
|
||||||
}
|
}
|
||||||
@ -276,7 +279,8 @@ export type CommandArgument<
|
|||||||
| boolean
|
| boolean
|
||||||
| ((
|
| ((
|
||||||
commandBarContext: { argumentsToSubmit: Record<string, unknown> }, // Should be the commandbarMachine's context, but it creates a circular dependency
|
commandBarContext: { argumentsToSubmit: Record<string, unknown> }, // Should be the commandbarMachine's context, but it creates a circular dependency
|
||||||
machineContext?: ContextFrom<T>
|
machineContext?: ContextFrom<T>,
|
||||||
|
fileMachineContext?: ContextFrom<typeof fileMachine>
|
||||||
) => boolean)
|
) => boolean)
|
||||||
skip?: boolean
|
skip?: boolean
|
||||||
machineActor?: Actor<T>
|
machineActor?: Actor<T>
|
||||||
|
|||||||
Reference in New Issue
Block a user