aboutsummaryrefslogtreecommitdiff
path: root/src/client/views/collections/CollectionViewChromes.tsx
diff options
context:
space:
mode:
authorBob Zeleznik <zzzman@gmail.com>2020-03-25 20:57:22 -0400
committerBob Zeleznik <zzzman@gmail.com>2020-03-25 20:57:22 -0400
commitd50415122ea6d4b87f1604fa4611553103fa2c18 (patch)
tree5037b5f932ade6703026c33f9eff7c6c16c85d27 /src/client/views/collections/CollectionViewChromes.tsx
parent786572f3cd674459f55b7f66e8eb257026f373ef (diff)
set max size for tab titles. fixed collection sizing when filter is expanded. fixed pivot view text height when small collection.
Diffstat (limited to 'src/client/views/collections/CollectionViewChromes.tsx')
-rw-r--r--src/client/views/collections/CollectionViewChromes.tsx5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/client/views/collections/CollectionViewChromes.tsx b/src/client/views/collections/CollectionViewChromes.tsx
index ff55128f6..9391b153e 100644
--- a/src/client/views/collections/CollectionViewChromes.tsx
+++ b/src/client/views/collections/CollectionViewChromes.tsx
@@ -24,6 +24,7 @@ interface CollectionViewChromeProps {
CollectionView: CollectionView;
type: CollectionViewType;
collapse?: (value: boolean) => any;
+ PanelWidth: () => number;
}
interface Filter {
@@ -391,7 +392,7 @@ export class CollectionViewBaseChrome extends React.Component<CollectionViewChro
top: collapsed ? -70 : 0, height: collapsed ? 0 : undefined,
transform: collapsed ? "" : `scale(${Math.min(1, this.props.CollectionView.props.ScreenToLocalTransform().Scale)})`,
transformOrigin: "top left",
- width: `${100 / Math.min(1, this.props.CollectionView.props.ScreenToLocalTransform().Scale)}%`
+ width: `${this.props.PanelWidth() / Math.min(1, this.props.CollectionView.props.ScreenToLocalTransform().Scale)}px`
}}>
<div className="collectionViewChrome" style={{ border: "unset" }}>
<div className="collectionViewBaseChrome">
@@ -598,7 +599,7 @@ export class CollectionSchemaViewChrome extends React.Component<CollectionViewCh
togglePreview = () => {
const dividerWidth = 4;
const borderWidth = Number(COLLECTION_BORDER_WIDTH);
- const panelWidth = this.props.CollectionView.props.PanelWidth();
+ const panelWidth = this.props.PanelWidth();
const previewWidth = NumCast(this.props.CollectionView.props.Document.schemaPreviewWidth);
const tableWidth = panelWidth - 2 * borderWidth - dividerWidth - previewWidth;
this.props.CollectionView.props.Document.schemaPreviewWidth = previewWidth === 0 ? Math.min(tableWidth / 3, 200) : 0;