@loomhq/lens 10.68.3 → 10.69.0

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.
@@ -21,5 +21,6 @@ declare type MenuItemProps = {
21
21
  hasDivider?: boolean;
22
22
  children?: React.ReactNode;
23
23
  columns?: string;
24
+ hidden?: boolean;
24
25
  };
25
26
  export default Menu;
@@ -30,7 +30,7 @@ const MenuWrapper = styled.ul `
30
30
  ${getRadius('large')};
31
31
  `;
32
32
  const MenuItemWrapper = styled.li `
33
- display: grid;
33
+ display: ${({ hidden }) => (hidden ? 'none' : 'grid')};
34
34
  grid-auto-flow: column;
35
35
  grid-template-columns: ${props => props.columns};
36
36
  ${getSize('grid-gap', 'small')};
@@ -1,4 +1,4 @@
1
- import React from 'react';
1
+ import React, { HTMLAttributes } from 'react';
2
2
  declare const SelectWrapper: import("@emotion/styled-base").StyledComponent<React.DetailedHTMLProps<React.HTMLAttributes<HTMLDivElement>, HTMLDivElement>, Pick<React.ClassAttributes<HTMLDivElement> & React.HTMLAttributes<HTMLDivElement>, keyof React.HTMLAttributes<HTMLDivElement>>, object>;
3
3
  declare const Select: ({ container, onChange, menuZIndex, menuMaxWidth, menuMaxHeight, selectedOptionValue, onOuterClick, options, placeholder, isDisabled, onOpenChange, trigger, ...props }: SelectProps & React.ComponentProps<typeof SelectWrapper>) => JSX.Element;
4
4
  declare type OptionsObject = {
@@ -7,6 +7,7 @@ declare type OptionsObject = {
7
7
  icon?: React.ReactNode;
8
8
  isDisabled?: boolean;
9
9
  hasDivider?: boolean;
10
+ hidden?: HTMLAttributes<HTMLOptionElement>['hidden'];
10
11
  };
11
12
  declare type SelectProps = {
12
13
  onChange?: React.ReactEventHandler;
@@ -193,7 +193,7 @@ const Select = (_a) => {
193
193
  isOpen &&
194
194
  renderLayer(React.createElement("div", Object.assign({}, layerProps, { style: Object.assign(Object.assign({}, layerProps.style), { zIndex: menuZIndex, width: triggerBounds === null || triggerBounds === void 0 ? void 0 : triggerBounds.width }) }),
195
195
  React.createElement(Menu, { downshiftMenuProps: getMenuProps, maxWidth: menuMaxWidth, maxHeight: menuMaxHeight }, options.map((item, index) => {
196
- return (React.createElement(MenuItem, Object.assign({ key: index, getItemProps: getItemProps, icon: item.icon }, getItemProps({
196
+ return (React.createElement(MenuItem, Object.assign({ key: index, getItemProps: getItemProps, icon: item.icon, hidden: item.hidden }, getItemProps({
197
197
  key: `${item.value}-${index}`,
198
198
  index,
199
199
  item,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@loomhq/lens",
3
- "version": "10.68.3",
3
+ "version": "10.69.0",
4
4
  "scripts": {
5
5
  "dev": "next",
6
6
  "build:next": "next build",