@woven-planet/lakefront
v13.0.0
Published
React UI Components
Readme
lakefront
Lakefront is a simple React component library.
Installation
Lakefront is available as an npm package.
// with npm
npm install @woven-planet/lakefront
// with yarn
yarn add @woven-planet/lakefrontEmotion's ThemeProvider must wrap your application for the components to style correctly.
import { ThemeProvider } from '@emotion/react';
import { theme } from '@woven-planet/lakefront';
<ThemeProvider theme={theme}>
...
</ThemeProvider>Usage
⚠️ LakeFront requires the client application to use the React and Node versions listed in the package.json ⚠️
Here is a quick example to get you started, it's all you need:
import { createRoot } from 'react-dom/client';
import { Button } from '@woven-planet/lakefront';
function App() {
return <Button>Hello World</Button>;
}
createRoot.render(<App />, document.querySelector('#app'));
Contributing
If you want to contribute to the action, even by just raising a problem or proposing an idea, you can click here to find out how to do it.
Npm Dependencies Maintenance
Dependencies in the package.json should be kept up to date to avoid unexpected issues. A report of
outdated dependencies is rebuilt nightly and published to
the dependencies page, alongside the Storybook. It covers
both dependencies and devDependencies, and the same content is written to the workflow's job summary so a failed
publish does not lose it.
Review cadence
Review it once per sprint, at planning:
- Open the report. Anything under Patch or Minor is routine; apply it as one pull request.
- For each new entry under Major, raise a ticket rather than attempting it inline.
- Check the repository's security alerts as well. The report shows versions, not vulnerabilities, so it will not surface a CVE on a package that is otherwise current.
The react-table 9 migration, and what it actually involved
@tanstack/react-table 9 was the last outstanding major, and it was far less of a rewrite than it looked. An
earlier reading of the release notes here claimed getRowModel, getHeaderGroups, getAllLeafColumns and
getState were all gone. Only getState is, replaced by table.state, and this library never called it. The
other three are declared on core features that the table composes unconditionally, so they survive unrenamed and
the render path in Table.tsx was re-typed rather than rewritten.
What did change, and is worth knowing before touching the table again:
- Features are opt-in.
tableFeatures()insrc/components/Table/tableFeatures.tsis the contract: calling an instance method whose feature is not registered there is a type error. Only sorting, row expanding, column visibility, column sizing, column resizing and cell spanning are registered, so nothing else reaches the bundle. TableFeaturesis the first type argument on nearly every type.src/components/Table/tableTypes.tsbinds it once and exports aliases, so a consumer's column definitions need no feature argument and did not have to change.TableColumnis still the public name for a column definition.VisibilityStatewas renamedColumnVisibilityState. The old name is kept as an alias intableTypes.ts, so the prop names here and in consuming applications stayed put.- The core row model is automatic, so there is no
getCoreRowModel()any more; the other row models register insidetableFeatures()rather than as table options. columnDef.metais typed per-table through thecolumnMetaslot rather than by declaration merging onColumnMeta. Merging would impose this library's meta shape on every unrelated table in a consuming application.
Two gates mattered and are worth keeping for any future change to this component: a visual pass over all 18 Table
stories, since src/stories sits outside type-check and most of its column fixtures are untyped object literals,
and a build-copy check against a consuming application.
Toolchain notes worth keeping
Two constraints are easy to trip over when touching the build:
- Linting and formatting are Biome, not ESLint, configured in
biome.jsonc.npm run lintrunsbiome check, which covers lint, format and import order together;npm run lint:fixwrites the fixes. Biome parses TypeScript itself, so linting is not tied to the compiler version the way ESLint was: typescript-eslint refuses TypeScript 7 outright, from a runtime guard, with no release or canary that allows it. Each non-default choice in the config carries a comment explaining itself. isolatedModulesis required, not optional. swc transpiles one file at a time and cannot tell an interface from a value, so every type re-export needs the inlinetypemodifier. Removing the flag would let the build break at bundle time rather than at type-check time.
Three high findings also have no published fix: @storybook/builder-webpack5, @storybook/react-webpack5 and
webpack-dev-middleware, all reached only through the Storybook dev server.
Storybook Components
We've added Storybook pages to show how each component can be used.
How to add components to this table
Upon a new component being added to this table run 'npm run update-readme' for boilerplate code. Please replace the three variables with the corresponding information as needed. Also, store screenshots of components in the 'screenshots' folder.
Please do not add information below this table, the 'npm run update-readme' will not work properly if the table is not last.
| Component | Picture | Component | Picture | |:-------------------------------------------------------------------------------------------------------------------------------------------|:-----------------------------------------------------------------------------------------------------|:-----------------------------------------------------------------------------------------------------------------------------------------------------|:--------------------------------------------------------------------------------------------------------| | AnchorCopy | Screenshot | BoundingBoxes | Screenshot | | Breadcrumb | Screenshot | Button | Screenshot | | Card | Screenshot | Checkbox | Screenshot | | CheckboxGroup | Screenshot | PopoverContent | Screenshot | | Collapsible | Screenshot | CopyButton | Screenshot | | Drawer | Screenshot | Filter | Screenshot | | AdditionalJSONFilter | Screenshot | DoubleMultiSelectFilter | Screenshot | | DurationFilter | Screenshot | ListFilter | Screenshot | | MultiSelectFilter | Screenshot | RadioFilter | Screenshot | | SingleSelectFilter | Screenshot | TextFilter | Screenshot | | Header | Screenshot | Input | Screenshot | | ItemGrid | Screenshot | ItemResults | Screenshot | | Loading | Screenshot | MaskableImage | Screenshot | | Modal | Screenshot | ConfirmationModal | Screenshot | | Page | Screenshot | PlaybackBar | Screenshot | | Progress | Screenshot | Circular Progress | Screenshot | | Device Progress | Screenshot | Progress Bar | Screenshot | | PropertyList | Screenshot | RadioGroup | Screenshot | | RefreshToolBar | Screenshot | Select | Screenshot | | SelectPopover | Screenshot | Snackbar | Screenshot | | SpeedInput | Screenshot | StackBanner | Screenshot | | StackBannerRow | Screenshot | StepFunctionAuthoring | Screenshot | | StatusTable | Screenshot | StatusTracker | Screenshot | | StatusTrackerPopover | Screenshot | StepFunctionGraph | Screenshot | | StepFunctionRenderer | Screenshot | Table | Screenshot | | Tabs | Screenshot | TextArea | Screenshot | | Toggle | Screenshot | TypeaheadSearch | Screenshot | | ModeSelector | Screenshot | Colors | Screenshot | | ContextMenu | Screenshot | ButtonGroup | Screenshot |
