Skip to content

Commit

Permalink
[refactor] GH-11 Full-screen controls in stories
Browse files Browse the repository at this point in the history
  • Loading branch information
amivanoff committed Sep 9, 2021
1 parent 164b9e4 commit b126a41
Show file tree
Hide file tree
Showing 7 changed files with 54 additions and 42 deletions.
12 changes: 6 additions & 6 deletions stories/TableLocalArtifacts.stories.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -937,9 +937,9 @@ const Template: Story = (args: any) => {
// eslint-disable-next-line @typescript-eslint/no-var-requires
connectReduxDevtools(require('remotedev'), rootStore);
return (
<Provider store={store}>
<MstContextProvider store={rootStore} renderers={antdRenderers} cells={antdCells}>
<div style={{ height: '1000px' }}>
<div style={{ height: 'calc(100vh - 32px)' }}>
<Provider store={store}>
<MstContextProvider store={rootStore} renderers={antdRenderers} cells={antdCells}>
<JsonSchemaTable
schema={artifactSchema}
path=''
Expand Down Expand Up @@ -1011,9 +1011,9 @@ const Template: Story = (args: any) => {
},
}}
/>
</div>
</MstContextProvider>
</Provider>
</MstContextProvider>
</Provider>
</div>
);
};

Expand Down
12 changes: 6 additions & 6 deletions stories/TableRemoteArtifacts.stories.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -240,13 +240,13 @@ const Template: Story = (args: any) => {
// eslint-disable-next-line @typescript-eslint/no-var-requires
connectReduxDevtools(require('remotedev'), rootStore);
return (
<Provider store={store}>
<MstContextProvider store={rootStore} renderers={antdRenderers} cells={antdCells}>
<div style={{ height: '1000px' }}>
<div style={{ height: 'calc(100vh - 32px)' }}>
<Provider store={store}>
<MstContextProvider store={rootStore} renderers={antdRenderers} cells={antdCells}>
<Form viewDescrId={viewDescrs[0]['@id']} viewDescrCollId={viewDescrCollConstr['@id']} />
</div>
</MstContextProvider>
</Provider>
</MstContextProvider>
</Provider>
</div>
);
};

Expand Down
12 changes: 6 additions & 6 deletions stories/TableRemoteMktp.stories.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -303,13 +303,13 @@ const Template: Story = (args: any) => {
// eslint-disable-next-line @typescript-eslint/no-var-requires
connectReduxDevtools(require('remotedev'), rootStore);
return (
<Provider store={store}>
<MstContextProvider store={rootStore} renderers={antdRenderers} cells={antdCells}>
<div style={{ height: '1080px' }}>
<div style={{ height: 'calc(100vh - 32px)' }}>
<Provider store={store}>
<MstContextProvider store={rootStore} renderers={antdRenderers} cells={antdCells}>
<Form viewDescrId={viewDescrs[0]['@id']} viewDescrCollId={viewDescrCollConstr['@id']} />
</div>
</MstContextProvider>
</Provider>
</MstContextProvider>
</Provider>
</div>
);
};

Expand Down
16 changes: 10 additions & 6 deletions stories/TreeAndFormArtifact.stories.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -64,6 +64,10 @@ const viewKinds = [
'@id': 'rm:_kf8Df7',
'@type': 'aldkg:SplitPaneLayout',
options: {
style: {
width: '100%',
height: '50%',
},
defaultSize: {
'rm:Folders_Coll': '17%',
'rm:_fgu778f': '83%',
Expand Down Expand Up @@ -181,12 +185,12 @@ export const Empty: Story<{}> = () => {
// eslint-disable-next-line @typescript-eslint/no-var-requires
connectReduxDevtools(require('remotedev'), rootStore);
return (
<Provider store={store}>
<MstContextProvider store={rootStore} renderers={antdRenderers} cells={antdCells}>
<div style={{ height: '1000px', width: '100%' }}>
<div style={{ height: 'calc(100vh - 32px)' }}>
<Provider store={store}>
<MstContextProvider store={rootStore} renderers={antdRenderers} cells={antdCells}>
<Form viewDescrId={viewDescrs[0]['@id']} viewDescrCollId={viewDescrCollConstr['@id']} />
</div>
</MstContextProvider>
</Provider>
</MstContextProvider>
</Provider>
</div>
);
};
12 changes: 6 additions & 6 deletions stories/TreeAndFormMktp.stories.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -388,12 +388,12 @@ export const Empty: Story<{}> = () => {
// eslint-disable-next-line @typescript-eslint/no-var-requires
connectReduxDevtools(require('remotedev'), rootStore);
return (
<Provider store={store}>
<MstContextProvider store={rootStore} renderers={antdRenderers} cells={antdCells}>
<div style={{ height: '1000px', width: '100%' }}>
<div style={{ height: 'calc(100vh - 32px)' }}>
<Provider store={store}>
<MstContextProvider store={rootStore} renderers={antdRenderers} cells={antdCells}>
<Form viewDescrId={viewDescrs[0]['@id']} viewDescrCollId={viewDescrCollConstr['@id']} />
</div>
</MstContextProvider>
</Provider>
</MstContextProvider>
</Provider>
</div>
);
};
16 changes: 10 additions & 6 deletions stories/TwoTables.stories.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -102,6 +102,10 @@ const viewKinds = [
'@id': 'mktp:_97hFH67',
'@type': 'aldkg:SplitPaneLayout',
options: {
style: {
width: '100%',
height: '100%',
},
defaultSize: {
'mktp:MarketplacesTabs': '17%',
'mktp:CategoryCardsTable': '43',
Expand Down Expand Up @@ -599,13 +603,13 @@ const Template: Story = (args: any) => {
// eslint-disable-next-line @typescript-eslint/no-var-requires
connectReduxDevtools(require('remotedev'), rootStore);
return (
<Provider store={store}>
<MstContextProvider store={rootStore} renderers={antdRenderers} cells={antdCells}>
<div style={{ height: '1080px' }}>
<div style={{ height: 'calc(100vh - 32px)' }}>
<Provider store={store}>
<MstContextProvider store={rootStore} renderers={antdRenderers} cells={antdCells}>
<Form viewDescrId={viewDescrs[0]['@id']} viewDescrCollId={viewDescrCollConstr['@id']} />
</div>
</MstContextProvider>
</Provider>
</MstContextProvider>
</Provider>
</div>
);
};

Expand Down
16 changes: 10 additions & 6 deletions stories/TwoTablesBig.stories.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -102,6 +102,10 @@ const viewKinds = [
'@id': 'mktp:_97hFH67',
'@type': 'aldkg:SplitPaneLayout',
options: {
style: {
width: '100%',
height: '100%',
},
defaultSize: {
'mktp:MarketplacesTabs': '17%',
'mktp:CategoryCardsTable': '43',
Expand Down Expand Up @@ -602,13 +606,13 @@ const Template: Story = (args: any) => {
// eslint-disable-next-line @typescript-eslint/no-var-requires
connectReduxDevtools(require('remotedev'), rootStore);
return (
<Provider store={store}>
<MstContextProvider store={rootStore} renderers={antdRenderers} cells={antdCells}>
<div style={{ height: '1080px' }}>
<div style={{ height: 'calc(100vh - 32px)' }}>
<Provider store={store}>
<MstContextProvider store={rootStore} renderers={antdRenderers} cells={antdCells}>
<Form viewDescrId={viewDescrs[0]['@id']} viewDescrCollId={viewDescrCollConstr['@id']} />
</div>
</MstContextProvider>
</Provider>
</MstContextProvider>
</Provider>
</div>
);
};

Expand Down

0 comments on commit b126a41

Please sign in to comment.