Skip to content

Commit

Permalink
Merge branch 'master' into add-metasection-props-to-readme
Browse files Browse the repository at this point in the history
  • Loading branch information
ncovercash authored Jan 4, 2024
2 parents dc619c7 + 99cfe5b commit 11a2d19
Show file tree
Hide file tree
Showing 3 changed files with 49 additions and 3 deletions.
2 changes: 2 additions & 0 deletions lib/InfoPopover/readme.md
Original file line number Diff line number Diff line change
Expand Up @@ -25,5 +25,7 @@ contentClass | string | `className` for content inside popover |
iconSize | string | The size of the icon (`small` or `medium`) | small
hideOnButtonClick | boolean | Whether to hide popover on anchor button click | false
renderTrigger | func | Render a custom trigger button. The function will receive an object that contains the the `open`-state, a `ref` that needs to be passed onto trigger button and a `toggle`-function for toggling the `<InfoPopover>`. The render function should return a button. |
buttonProps | object | Pass additional props to the trigger `<IconButton>` | `{}`
popperProps | object | Pass additional props to the underlying `<Popper>` | `{}`

The remaining props passed to `<InfoPopover>` will be passed down to the internal `<Popover>`.
39 changes: 36 additions & 3 deletions lib/Loading/readme.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,39 @@

Components for loading animations for various scenarios within your application.

- `<Loading>` a basic, standalone loading spinner
- `<LoadingPane>` a Pane with a loading spinner. For use within existing `<Paneset>`s. Accepts the props of `<Pane>`.
- `<LoadingView>` for fullscreen views. Accepts the props of `<Pane>` and includes a wrapping `<Paneset>`.
## `<Loading>`: a basic, standalone loading spinner

| Property | Type | Description | Default | Required |
| --- | --- | --- | --- | --- |
| size | `small`, `medium`, `large`, or `xlarge` | The size of the loading icon | `medium` | |
| useCurrentColor | boolean | If the current element's CSS text `color` should be used instead of the default grey | `false` | |

### Example

```jsx
<Loading />
```

## `<LoadingPane>`: a Pane with a loading spinner

For use within existing `<Paneset>`s. Accepts the props of `<Pane>`.

Accepts all properties of [<Pane>](https://github.com/folio-org/stripes-components/blob/master/lib/Pane/readme.md#props), however,
`defaultWidth` is optional (set to `fill` by default). Any provided `children` will be ignored.

### Example

```jsx
<LoadingPane defaultWidth="20%" paneTitle="Filters" />
```

## `<LoadingView>`: for fullscreen views

Accepts the same props as `<LoadingPane>`, with the addition of `panesetProps`. `panesetProps` will be passed to the underlying
`<Paneset>` and all other props will be passed to the underlying `<Pane>`.

### Example

```jsx
<LoadingView paneTitle="Content" panesetProps={{isRoot: true}} />
```
11 changes: 11 additions & 0 deletions lib/Spinner/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
# Spinner

Renders a loading spinner icon.

## Props
None

## Usage
```jsx
<Spinner />
```

0 comments on commit 11a2d19

Please sign in to comment.