2025-02-07 11:30:36 -05:00
|
|
|
import { OnboardingButtons, kbdClasses, useDemoCode } from '.'
|
2024-02-11 12:59:00 +11:00
|
|
|
import { onboardingPaths } from 'routes/Onboarding/paths'
|
2024-03-29 12:56:32 -04:00
|
|
|
import { bracketWidthConstantLine } from 'lib/exampleKcl'
|
2023-09-15 22:37:40 -04:00
|
|
|
|
2024-06-20 21:39:01 -04:00
|
|
|
export default function OnboardingInteractiveNumbers() {
|
|
|
|
useDemoCode()
|
2023-09-15 22:37:40 -04:00
|
|
|
|
|
|
|
return (
|
|
|
|
<div className="fixed grid justify-end items-center inset-0 z-50 pointer-events-none">
|
|
|
|
<div
|
|
|
|
className={
|
2025-02-07 11:30:36 -05:00
|
|
|
'relative pointer-events-auto z-10 max-w-xl border border-chalkboard-50 dark:border-chalkboard-80 shadow-lg h-[75vh] flex flex-col justify-center bg-chalkboard-10 dark:bg-chalkboard-90 p-8 rounded'
|
2023-09-15 22:37:40 -04:00
|
|
|
}
|
|
|
|
>
|
|
|
|
<section className="flex-1 overflow-y-auto mb-6">
|
2024-03-08 17:59:14 -05:00
|
|
|
<h2 className="text-3xl font-bold">Hybrid editing</h2>
|
|
|
|
|
2023-09-15 22:37:40 -04:00
|
|
|
<p className="my-4">
|
2024-03-29 12:56:32 -04:00
|
|
|
We believe editing in Modeling App should feel fluid between code
|
|
|
|
and point-and-click, so that you can work in the way that feels most
|
|
|
|
natural to you. Let's try something out that demonstrates this
|
|
|
|
principle, by editing numbers without typing.
|
|
|
|
</p>
|
|
|
|
<ol className="pl-6 my-4 list-decimal">
|
|
|
|
<li className="list-decimal">
|
|
|
|
Press and hold the <kbd className={kbdClasses}>Alt</kbd> (or{' '}
|
|
|
|
<kbd className={kbdClasses}>Option</kbd>) key
|
|
|
|
</li>
|
|
|
|
<li>
|
2024-06-20 21:39:01 -04:00
|
|
|
Hover over the number assigned to "width" on{' '}
|
|
|
|
<em>
|
|
|
|
<strong>line {bracketWidthConstantLine}</strong>
|
|
|
|
</em>
|
2024-03-29 12:56:32 -04:00
|
|
|
</li>
|
|
|
|
<li>Drag the number left and right to change its value</li>
|
|
|
|
</ol>
|
|
|
|
<p className="my-4">
|
|
|
|
You can hold down different modifier keys to change the value by
|
|
|
|
different increments:
|
2023-09-15 22:37:40 -04:00
|
|
|
</p>
|
2024-03-08 17:59:14 -05:00
|
|
|
<ul className="flex flex-col text-sm my-4 mx-12 divide-y divide-chalkboard-20 dark:divide-chalkboard-70">
|
|
|
|
<li className="flex justify-between m-0 px-0 py-2">
|
|
|
|
<kbd className={kbdClasses}>Alt + Shift + Cmd/Win</kbd>
|
|
|
|
±0.01
|
|
|
|
</li>
|
|
|
|
<li className="flex justify-between m-0 px-0 py-2">
|
|
|
|
<kbd className={kbdClasses}>Alt + Cmd/Win</kbd>
|
|
|
|
±0.1
|
|
|
|
</li>
|
|
|
|
<li className="flex justify-between m-0 px-0 py-2">
|
|
|
|
<kbd className={kbdClasses}>Alt</kbd>±1
|
|
|
|
</li>
|
|
|
|
<li className="flex justify-between m-0 px-0 py-2">
|
|
|
|
<kbd className={kbdClasses}>Alt + Shift</kbd>
|
|
|
|
±10
|
|
|
|
</li>
|
|
|
|
</ul>
|
2023-09-15 22:37:40 -04:00
|
|
|
<p className="my-4">
|
|
|
|
Our code editor is built with{' '}
|
|
|
|
<a
|
|
|
|
href="https://codemirror.net/"
|
|
|
|
target="_blank"
|
|
|
|
rel="noreferrer noopeneer"
|
|
|
|
>
|
|
|
|
CodeMirror
|
|
|
|
</a>
|
|
|
|
, a great open-source project with extensions that make it even more
|
|
|
|
dynamic and interactive, including{' '}
|
|
|
|
<a
|
|
|
|
href="https://github.com/replit/codemirror-interact/"
|
|
|
|
target="_blank"
|
|
|
|
rel="noreferrer noopeneer"
|
|
|
|
>
|
|
|
|
one by the Replit team
|
|
|
|
</a>{' '}
|
|
|
|
lets you interact with numbers in your code by dragging them around.
|
|
|
|
</p>
|
|
|
|
<p className="my-4">
|
2024-03-29 12:56:32 -04:00
|
|
|
We're going to keep extending the text editor, and we'd love to hear
|
|
|
|
your ideas for how to make it better.
|
2023-09-15 22:37:40 -04:00
|
|
|
</p>
|
|
|
|
</section>
|
2025-02-07 11:30:36 -05:00
|
|
|
<OnboardingButtons currentSlug={onboardingPaths.INTERACTIVE_NUMBERS} />
|
2023-09-15 22:37:40 -04:00
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
)
|
|
|
|
}
|