Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 9 additions & 1 deletion examples/StyledExample.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,15 @@ import { SplitPane, Pane } from '../src';
import type { DividerProps } from '../src/types';

function CustomDivider(props: DividerProps) {
const { direction, isDragging, disabled, onMouseDown, onTouchStart, onTouchEnd, onKeyDown } = props;
const {
direction,
isDragging,
disabled,
onMouseDown,
onTouchStart,
onTouchEnd,
onKeyDown,
} = props;

return (
<div
Expand Down
8 changes: 7 additions & 1 deletion examples/main.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,13 @@ import { SnapPointsExample } from './SnapPointsExample';
import { PercentageExample } from './PercentageExample';
import './styles.css';

type Example = 'basic' | 'nested' | 'controlled' | 'styled' | 'snap' | 'percent';
type Example =
| 'basic'
| 'nested'
| 'controlled'
| 'styled'
| 'snap'
| 'percent';

const examples: { id: Example; label: string; shortLabel: string }[] = [
{ id: 'basic', label: 'Basic', shortLabel: 'Basic' },
Expand Down
1 change: 1 addition & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,7 @@
"format": "prettier --write src examples",
"format:check": "prettier --check src examples",
"typecheck": "tsc --noEmit",
"checks": "npm run typecheck && npm run lint && npm run format && npm run test",
"examples": "vite --config examples/vite.config.ts",
"examples:build": "vite build --config examples/vite.config.ts",
"prepublishOnly": "npm run test && npm run build"
Expand Down