diff --git a/plasmicpkgs/react-aria/src/registerComboBox.tsx b/plasmicpkgs/react-aria/src/registerComboBox.tsx index 83fdf173f2f..fd74ba6f43d 100644 --- a/plasmicpkgs/react-aria/src/registerComboBox.tsx +++ b/plasmicpkgs/react-aria/src/registerComboBox.tsx @@ -40,7 +40,6 @@ export interface BaseComboboxProps extends ComboBoxProps<{}>, WithVariants, HasControlContextData { - placeholder?: string; children?: React.ReactNode; isOpen?: boolean; className?: string; @@ -127,7 +126,6 @@ export function registerComboBox(loader?: Registerable) { ...getCommonProps("ComboBox", [ "name", "aria-label", - "placeholder", "isDisabled", ]), selectedKey: { @@ -187,12 +185,16 @@ export function registerComboBox(loader?: Registerable) { }, { type: "hbox", + styles: { + padding: 0, + }, children: [ { type: "component", name: INPUT_COMPONENT_NAME, styles: { width: "100%", + borderRightWidth: 0, }, }, { @@ -206,6 +208,10 @@ export function registerComboBox(loader?: Registerable) { styles: { width: "15px", transform: "rotate(180deg)", + display: "flex", + alignItems: "center", + justifyContent: "center", + padding: 0, }, }, }, diff --git a/plasmicpkgs/react-aria/src/registerInput.tsx b/plasmicpkgs/react-aria/src/registerInput.tsx index 691807096a7..af228548ee8 100644 --- a/plasmicpkgs/react-aria/src/registerInput.tsx +++ b/plasmicpkgs/react-aria/src/registerInput.tsx @@ -27,6 +27,7 @@ export interface BaseInputProps WithVariants { autoComplete?: string[]; isUncontrolled?: boolean; + typographyClassName?: string; } export const inputHelpers = { @@ -46,6 +47,8 @@ export function BaseInput(props: BaseInputProps) { disabled, autoComplete, value, + typographyClassName, + className, ...rest } = props; const textFieldContext = React.useContext(PlasmicTextFieldContext); @@ -78,6 +81,7 @@ export function BaseInput(props: BaseInputProps) { return ( { plasmicUpdateVariant?.({ @@ -114,6 +118,20 @@ export function registerInput( importPath: "@plasmicpkgs/react-aria/skinny/registerInput", importName: "BaseInput", variants, + // Excluding typography + styleSections: [ + "visibility", + "sizing", + "spacing", + "background", + "transform", + "transitions", + "layout", + "overflow", + "border", + "shadows", + "effects", + ], defaultStyles: { width: "300px", borderWidth: "1px", @@ -152,6 +170,19 @@ export function registerInput( "onBeforeInput", "onInput", ]), + typographyClassName: { + type: "class", + displayName: "Typography", + selectors: [ + // Plasmic Studio user can also in addition style the button's + // hovered and pressed state + { + selector: ":self::placeholder", + label: "Placeholder", + }, + ], + styleSections: ["typography"], + }, }, states: { value: { @@ -162,6 +193,7 @@ export function registerInput( ...inputHelpers.states.value, }, }, + componentHelpers: { helpers: inputHelpers, importName: "inputHelpers", diff --git a/plasmicpkgs/react-aria/src/registerSelect.tsx b/plasmicpkgs/react-aria/src/registerSelect.tsx index 1862dc1660a..99252fd82f9 100644 --- a/plasmicpkgs/react-aria/src/registerSelect.tsx +++ b/plasmicpkgs/react-aria/src/registerSelect.tsx @@ -74,7 +74,6 @@ export function BaseSelect(props: BaseSelectProps) { const { selectedKey, onSelectionChange, - placeholder, onOpenChange, isDisabled, className, @@ -106,7 +105,6 @@ export function BaseSelect(props: BaseSelectProps) { return (