diff --git a/apps/builder/app/builder/features/settings-panel/variable-popover.tsx b/apps/builder/app/builder/features/settings-panel/variable-popover.tsx
index 86d95203f8..c2a9850b2a 100644
--- a/apps/builder/app/builder/features/settings-panel/variable-popover.tsx
+++ b/apps/builder/app/builder/features/settings-panel/variable-popover.tsx
@@ -28,7 +28,6 @@ import {
ProBadge,
ScrollArea,
Select,
- SelectItem,
Switch,
TextArea,
Tooltip,
@@ -48,7 +47,6 @@ import {
invalidateResource,
} from "~/shared/nano-states";
import { serverSyncStore } from "~/shared/sync";
-import { humanizeString } from "~/shared/string-utils";
import {
useField,
type Field,
@@ -390,40 +388,57 @@ const VariablePanel = forwardRef<
}
return "string";
});
- const typeOptions: VariableType[] = [
- "string",
- "number",
- "boolean",
- "json",
- "resource",
- ];
- const getTypeLabel = (value: VariableType) =>
- value === "json" ? "JSON" : humanizeString(value);
+
+ const typeOptions: Map<
+ VariableType,
+ { label: ReactNode; description: string }
+ > = new Map([
+ ["string", { label: "String", description: "Any alphanumeric text." }],
+ [
+ "number",
+ {
+ label: "Number",
+ description: "Any number, can be used in math expressions.",
+ },
+ ],
+ [
+ "boolean",
+ { label: "Boolean", description: "A boolean is a true/false switch." },
+ ],
+ ["json", { label: "JSON", description: "Any JSON value" }],
+ [
+ "resource",
+ {
+ label: (
+
+ Resource
+ {allowDynamicData === false && Pro}
+
+ ),
+ description:
+ "A Resource is a configuration for secure data fetching. You can safely use secrets in any field.",
+ },
+ ],
+ ]);
const typeFieldElement = (
-
+
-
);
diff --git a/packages/design-system/src/components/select.tsx b/packages/design-system/src/components/select.tsx
index f52e622136..92605459d7 100644
--- a/packages/design-system/src/components/select.tsx
+++ b/packages/design-system/src/components/select.tsx
@@ -138,13 +138,16 @@ export type SelectProps