Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 6 additions & 6 deletions src/components/Container/index.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import { CLASS_FLEX, CLASS_GRID, CLASS_RESIZABLE, CLASS_SCROLLABLE } from '../../class';
import { Element, ElementArgs, IFlexArgs, IParentArgs } from '../Element';
import { Element, ElementArgs, IParentArgs } from '../Element';

const RESIZE_HANDLE_SIZE = 4;

Expand All @@ -21,7 +21,11 @@ const CLASS_DRAGGED_CHILD = `${CLASS_DRAGGED}-child`;
/**
* The arguments for the {@link Container} constructor.
*/
interface ContainerArgs extends ElementArgs, IParentArgs, IFlexArgs {
interface ContainerArgs extends ElementArgs, IParentArgs {
/**
* Sets whether the {@link Container} uses flex layout.
*/
flex?: boolean,
Comment thread
willeastcott marked this conversation as resolved.
/**
* Sets whether the {@link Container} is resizable and where the resize handle is located. Can
* be one of 'top', 'bottom', 'right', 'left'. Defaults to `null` which disables resizing.
Expand All @@ -47,10 +51,6 @@ interface ContainerArgs extends ElementArgs, IParentArgs, IFlexArgs {
* Sets whether the {@link Container} supports the grid layout.
*/
grid?: boolean,
/**
* Sets the {@link Container}'s align items property.
*/
alignItems?: string
}

/**
Expand Down
10 changes: 4 additions & 6 deletions src/components/Element/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -145,13 +145,11 @@ interface IParentArgs {
}

/**
* The interface for arguments for elements that use flex layout.
* The interface for flex-related CSS properties available on elements.
* These properties do not themselves enable `display: flex`; flex layout is
* configured separately (for example via `Container#flex`).
*/
interface IFlexArgs {
/**
* Sets whether the element uses flex layout.
*/
flex?: boolean,
/**
* Sets the element's `flexBasis` CSS property.
*/
Expand Down Expand Up @@ -193,7 +191,7 @@ interface IFlexArgs {
/**
* The arguments for the {@link Element} constructor.
*/
interface ElementArgs {
interface ElementArgs extends IFlexArgs {
Comment thread
willeastcott marked this conversation as resolved.
/**
* The HTMLElement to create this {@link Element} with. If not provided this Element will create one.
*/
Expand Down
4 changes: 2 additions & 2 deletions src/components/Label/index.ts
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
import { CLASS_DEFAULT_MOUSEDOWN, CLASS_MULTIPLE_VALUES } from '../../class';
import { Element, ElementArgs, IBindable, IBindableArgs, IFlexArgs, IPlaceholder, IPlaceholderArgs } from '../Element';
import { Element, ElementArgs, IBindable, IBindableArgs, IPlaceholder, IPlaceholderArgs } from '../Element';

const CLASS_LABEL = 'pcui-label';

/**
* The arguments for the {@link Label} constructor.
*/
interface LabelArgs extends ElementArgs, IBindableArgs, IPlaceholderArgs, IFlexArgs {
interface LabelArgs extends ElementArgs, IBindableArgs, IPlaceholderArgs {
/**
* Sets the text of the Label. Defaults to ''.
*/
Expand Down
4 changes: 2 additions & 2 deletions src/components/SliderInput/index.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import { CLASS_MULTIPLE_VALUES } from '../../class';
import { Element, ElementArgs, IBindable, IBindableArgs, IFlexArgs, IFocusable, IPlaceholder, IPlaceholderArgs } from '../Element';
import { Element, ElementArgs, IBindable, IBindableArgs, IFocusable, IPlaceholder, IPlaceholderArgs } from '../Element';
import { NumericInput } from '../NumericInput';

const CLASS_SLIDER = 'pcui-slider';
Expand All @@ -13,7 +13,7 @@ const IS_CHROME = /Chrome\//.test(globalThis.navigator?.userAgent);
/**
* The arguments for the {@link SliderInput} constructor.
*/
interface SliderInputArgs extends ElementArgs, IBindableArgs, IFlexArgs, IPlaceholderArgs {
interface SliderInputArgs extends ElementArgs, IBindableArgs, IPlaceholderArgs {
/**
* Sets whether any key up event will cause a change event to be fired.
*/
Expand Down