Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[ui] New component catalog #1003

Merged
merged 30 commits into from
Oct 18, 2022
Merged
Show file tree
Hide file tree
Changes from 2 commits
Commits
Show all changes
30 commits
Select commit Hold shift + click to select a range
79265b3
New component catalog
bharatkashyap Sep 14, 2022
65b55de
Merge branch 'master' into catalog-ui
bharatkashyap Sep 14, 2022
9d3fde7
Merge branch 'master' of github.com:mui/mui-toolpad into catalog-ui
bharatkashyap Sep 15, 2022
2f42f40
No need to lazy load, use an IconMap instead
bharatkashyap Sep 15, 2022
509cf14
Merge branch 'master' of github.com:mui/mui-toolpad into catalog-ui
bharatkashyap Sep 15, 2022
5d0170e
Use the sx prop better
bharatkashyap Sep 15, 2022
1ea010b
Merge branch 'master' into catalog-ui
bharatkashyap Sep 16, 2022
3df3b74
Merge branch 'master' of github.com:mui/mui-toolpad into catalog-ui
bharatkashyap Sep 20, 2022
5f2b096
Fix merge conflict
bharatkashyap Sep 20, 2022
0ca4912
Merge branch 'catalog-ui' of github.com:mui/mui-toolpad into catalog-ui
bharatkashyap Sep 20, 2022
e1b1a36
Fix more tests
bharatkashyap Sep 21, 2022
941638a
No need for this
bharatkashyap Sep 21, 2022
9f9bd67
Merge branch 'master' of github.com:mui/mui-toolpad into catalog-ui
bharatkashyap Oct 11, 2022
541c15f
Merge branch 'master' into catalog-ui
bharatkashyap Oct 11, 2022
be3fa46
Review Jan, Gerda
bharatkashyap Oct 11, 2022
87d73b5
Merge branch 'catalog-ui' of github.com:mui/mui-toolpad into catalog-ui
bharatkashyap Oct 11, 2022
9de5811
Merge branch 'master' into catalog-ui
bharatkashyap Oct 11, 2022
c77b103
Missed removing this
bharatkashyap Oct 11, 2022
25a12bc
Merge branch 'catalog-ui' of github.com:mui/mui-toolpad into catalog-ui
bharatkashyap Oct 11, 2022
3b30caa
This was for debugging only
bharatkashyap Oct 11, 2022
ad99ac2
Separate component ID and display name
bharatkashyap Oct 11, 2022
d73a5f5
Disable entire future section, padding tweaks
bharatkashyap Oct 11, 2022
536dc42
Merge branches 'catalog-ui' and 'master' of github.com:mui/mui-toolpa…
bharatkashyap Oct 13, 2022
ae8be91
Correct hover theming
bharatkashyap Oct 13, 2022
99e28ca
Update to handle new theme, scroll fixes
bharatkashyap Oct 14, 2022
a2e18e2
Move this to theme PR
bharatkashyap Oct 14, 2022
9a6a018
Merge branch 'master' into catalog-ui
bharatkashyap Oct 14, 2022
f3cd806
Make darkening theme agnostic
bharatkashyap Oct 18, 2022
e21ce41
Merge branch 'master' into catalog-ui
bharatkashyap Oct 18, 2022
7cefccb
Only for debug
bharatkashyap Oct 18, 2022
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 packages/toolpad-app/src/runtime/ComponentsContext.tsx
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import * as React from 'react';
import * as builtins from '@mui/toolpad-components';
import * as builtIns from '@mui/toolpad-components';
import {
ToolpadComponent,
ToolpadComponents,
Expand Down Expand Up @@ -49,15 +49,15 @@ export default function ComponentsContext({ dom, children }: ComponentsContextPr

for (const [id, componentDef] of Object.entries(catalog)) {
if (componentDef) {
if (componentDef.builtin) {
const builtin = (builtins as any)[componentDef.builtin];
if (componentDef.builtIn) {
const builtIn = (builtIns as any)[componentDef.builtIn];

if (!isToolpadComponent(builtin)) {
if (!isToolpadComponent(builtIn)) {
result[id] = createToolpadComponentThatThrows(
new Error(`Imported builtin "${componentDef.builtin}" is not a ToolpadComponent`),
new Error(`Imported builtIn "${componentDef.builtIn}" is not a ToolpadComponent`),
);
} else {
result[id] = builtin;
result[id] = builtIn;
}
}

Expand Down

This file was deleted.

Loading