@prefecthq/prefect-ui-library 3.2.3 → 3.2.4

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.
@@ -4,6 +4,7 @@ import { SchemaValuesV2 } from '../schemas';
4
4
  declare const _default: import("vue").DefineComponent<__VLS_TypePropsToOption<{
5
5
  deployment: Deployment;
6
6
  parameters?: SchemaValuesV2 | undefined;
7
+ disabled?: boolean | undefined;
7
8
  name?: string | undefined;
8
9
  }>, {}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
9
10
  submit: (value: DeploymentFlowRunCreateV2) => void;
@@ -11,6 +12,7 @@ declare const _default: import("vue").DefineComponent<__VLS_TypePropsToOption<{
11
12
  }, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<__VLS_TypePropsToOption<{
12
13
  deployment: Deployment;
13
14
  parameters?: SchemaValuesV2 | undefined;
15
+ disabled?: boolean | undefined;
14
16
  name?: string | undefined;
15
17
  }>>> & {
16
18
  onSubmit?: ((value: DeploymentFlowRunCreateV2) => any) | undefined;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@prefecthq/prefect-ui-library",
3
- "version": "3.2.3",
3
+ "version": "3.2.4",
4
4
  "private": false,
5
5
  "repository": {
6
6
  "type": "git",
@@ -68,7 +68,7 @@
68
68
  <p-button @click="emit('cancel')">
69
69
  Cancel
70
70
  </p-button>
71
- <p-button variant="default" type="submit">
71
+ <p-button variant="default" type="submit" :disabled>
72
72
  Submit
73
73
  </p-button>
74
74
  </template>
@@ -97,6 +97,7 @@
97
97
  const props = defineProps<{
98
98
  deployment: Deployment,
99
99
  parameters?: SchemaValues,
100
+ disabled?: boolean,
100
101
  name?: string,
101
102
  }>()
102
103
 
@@ -126,6 +127,10 @@
126
127
  const { errors, validate: validateParameters } = useSchemaValidation(schema, parameters)
127
128
 
128
129
  async function submit(): Promise<void> {
130
+ if (props.disabled) {
131
+ return
132
+ }
133
+
129
134
  if (shouldValidate.value) {
130
135
  try {
131
136
  const valid = (await Promise.all([