aboutsummaryrefslogtreecommitdiff
path: root/src/client/views/StyleProvider.tsx
diff options
context:
space:
mode:
authorbobzel <zzzman@gmail.com>2020-12-13 18:05:45 -0500
committerbobzel <zzzman@gmail.com>2020-12-13 18:05:45 -0500
commit9af7025b7c9e6181843594f5179166556041234c (patch)
treec6b15ab4801107db5be75dfca4afe1cc77479aaf /src/client/views/StyleProvider.tsx
parent7f39c20eefaa25b5e82d09c7cedd8ebd1b24af3f (diff)
removed ContentScaling={returnOne} from a lot of places
Diffstat (limited to 'src/client/views/StyleProvider.tsx')
-rw-r--r--src/client/views/StyleProvider.tsx4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/client/views/StyleProvider.tsx b/src/client/views/StyleProvider.tsx
index 28373952a..386e03f37 100644
--- a/src/client/views/StyleProvider.tsx
+++ b/src/client/views/StyleProvider.tsx
@@ -60,7 +60,7 @@ function toggleBackground(doc: Doc) {
}
export function testDocProps(toBeDetermined: any): toBeDetermined is DocumentViewProps {
- return (toBeDetermined?.ContentScaling) ? true : false;
+ return (toBeDetermined?.select) ? false : true;
}
//
@@ -126,7 +126,7 @@ export function DefaultStyleProvider(doc: Opt<Doc>, props: Opt<FieldViewProps |
`${darkScheme() ? "rgb(30, 32, 31) " : "#9c9396 "} ${StrCast(doc.boxShadow, "0.2vw 0.2vw 0.8vw")}`;
default:
return doc.z ? `#9c9396 ${StrCast(doc?.boxShadow, "10px 10px 0.9vw")}` : // if it's a floating doc, give it a big shadow
- backgroundHalo(doc) && doc.type !== DocumentType.INK ? (`${props?.styleProvider?.(doc, props, StyleProp.BackgroundColor)} ${StrCast(doc.boxShadow, `0vw 0vw ${(isBackground() ? 100 : 50) / ((docProps && (props as DocumentViewProps).ContentScaling()) || 1)}px`)}`) : // if it's just in a cluster, make the shadown roughly match the cluster border extent
+ backgroundHalo(doc) && doc.type !== DocumentType.INK ? (`${props?.styleProvider?.(doc, props, StyleProp.BackgroundColor)} ${StrCast(doc.boxShadow, `0vw 0vw ${(isBackground() ? 100 : 50) / ((docProps && (props as DocumentViewProps).ContentScaling?.()) || 1)}px`)}`) : // if it's just in a cluster, make the shadown roughly match the cluster border extent
isBackground() ? undefined : // if it's a background & has a cluster color, make the shadow spread really big
StrCast(doc.boxShadow, "");
}