Skip to content

🎥 Make videos programmatically with React

easier to drag handles

Jonny Burger74584811d137
diff --git a/packages/cli/src/editor/components/Splitter/SplitterHandle.tsx b/packages/cli/src/editor/components/Splitter/SplitterHandle.tsx
index 27aee1b7ab..db18a1e8ff 100644
--- a/packages/cli/src/editor/components/Splitter/SplitterHandle.tsx
+++ b/packages/cli/src/editor/components/Splitter/SplitterHandle.tsx
@@ -146,7 +146,12 @@ export const SplitterHandle: React.FC<{
return (
<div
ref={ref}
- className="remotion-splitter"
+ className={[
+ 'remotion-splitter',
+ context.orientation === 'horizontal'
+ ? 'remotion-splitter-horizontal'
+ : 'remotion-splitter-vertical',
+ ].join(' ')}
style={
context.orientation === 'horizontal' ? containerRow : containerColumn
}
diff --git a/packages/cli/styles/styles.css b/packages/cli/styles/styles.css
index 2fd82fff4a..c784eb176d 100644
--- a/packages/cli/styles/styles.css
+++ b/packages/cli/styles/styles.css
@@ -10,14 +10,47 @@ body {
}
.remotion-splitter {
- background-color: black;
- transition: background-color 0.2s ease;
user-select: none;
}
-.remotion-splitter:hover,
-.remotion-splitter-active {
- background-color: var(--remotion-cli-internals-blue);
+.remotion-splitter-horizontal {
+ transform: scaleY(2);
+ background: linear-gradient(
+ to bottom,
+ transparent 25%,
+ black 25%,
+ black 75%,
+ transparent
+ );
+}
+
+.remotion-splitter-horizontal:hover,
+.remotion-splitter-horizontal.remotion-splitter-active {
+ background: linear-gradient(
+ to bottom,
+ var(--remotion-cli-internals-blue),
+ var(--remotion-cli-internals-blue)
+ );
+}
+
+.remotion-splitter-vertical {
+ transform: scaleX(2);
+ background: linear-gradient(
+ to right,
+ transparent 25%,
+ black 25%,
+ black 75%,
+ transparent
+ );
+}
+
+.remotion-splitter-vertical:hover,
+.remotion-splitter-vertical.remotion-splitter-active {
+ background: linear-gradient(
+ to right,
+ var(--remotion-cli-internals-blue),
+ var(--remotion-cli-internals-blue)
+ );
}
input::-webkit-outer-spin-button,
@@ -31,7 +64,10 @@ textarea:focus,
button:focus,
a:focus {
outline: none;
- box-shadow: inset 1px 1px #555, inset -1px -1px #555, inset 1px -1px #555,
+ box-shadow:
+ inset 1px 1px #555,
+ inset -1px -1px #555,
+ inset 1px -1px #555,
inset -1px 1px #555;
border-radius: 0 !important;
}