@wordpress/grid 0.3.0 → 0.5.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +12 -0
- package/build/dashboard-grid/grid-item.cjs.map +2 -2
- package/build/dashboard-grid/index.cjs.map +2 -2
- package/build/dashboard-grid/resolve-fill-widths.cjs.map +2 -2
- package/build/dashboard-grid/types.cjs.map +1 -1
- package/build/dashboard-lanes/index.cjs.map +2 -2
- package/build/dashboard-lanes/lanes-item.cjs.map +2 -2
- package/build/dashboard-lanes/types.cjs.map +1 -1
- package/build/dashboard-lanes/use-lane-placement.cjs.map +2 -2
- package/build/shared/drag-overlay-drop-animation.cjs.map +2 -2
- package/build/shared/grid-overlay.cjs.map +2 -2
- package/build/shared/item-exit-overlay.cjs.map +2 -2
- package/build/shared/resize-handle.cjs.map +2 -2
- package/build/shared/types.cjs.map +1 -1
- package/build/shared/use-item-exit-animation.cjs.map +2 -2
- package/build/shared/use-layout-shift-animation.cjs.map +2 -2
- package/build-module/dashboard-grid/grid-item.mjs.map +2 -2
- package/build-module/dashboard-grid/index.mjs.map +2 -2
- package/build-module/dashboard-grid/resolve-fill-widths.mjs.map +2 -2
- package/build-module/dashboard-lanes/index.mjs.map +2 -2
- package/build-module/dashboard-lanes/lanes-item.mjs.map +2 -2
- package/build-module/dashboard-lanes/use-lane-placement.mjs.map +2 -2
- package/build-module/shared/drag-overlay-drop-animation.mjs.map +2 -2
- package/build-module/shared/grid-overlay.mjs.map +2 -2
- package/build-module/shared/item-exit-overlay.mjs.map +2 -2
- package/build-module/shared/resize-handle.mjs.map +2 -2
- package/build-module/shared/use-item-exit-animation.mjs.map +2 -2
- package/build-module/shared/use-layout-shift-animation.mjs.map +2 -2
- package/build-types/dashboard-grid/grid-item.d.ts.map +1 -1
- package/build-types/dashboard-grid/index.d.ts.map +1 -1
- package/build-types/dashboard-grid/resolve-fill-widths.d.ts +0 -3
- package/build-types/dashboard-grid/resolve-fill-widths.d.ts.map +1 -1
- package/build-types/dashboard-grid/stories/index.story.d.ts +0 -6
- package/build-types/dashboard-grid/stories/index.story.d.ts.map +1 -1
- package/build-types/dashboard-grid/types.d.ts +0 -3
- package/build-types/dashboard-grid/types.d.ts.map +1 -1
- package/build-types/dashboard-lanes/index.d.ts.map +1 -1
- package/build-types/dashboard-lanes/lanes-item.d.ts.map +1 -1
- package/build-types/dashboard-lanes/stories/index.story.d.ts +0 -6
- package/build-types/dashboard-lanes/stories/index.story.d.ts.map +1 -1
- package/build-types/dashboard-lanes/types.d.ts +0 -3
- package/build-types/dashboard-lanes/types.d.ts.map +1 -1
- package/build-types/dashboard-lanes/use-lane-placement.d.ts.map +1 -1
- package/build-types/shared/drag-overlay-drop-animation.d.ts.map +1 -1
- package/build-types/shared/grid-overlay.d.ts +0 -3
- package/build-types/shared/grid-overlay.d.ts.map +1 -1
- package/build-types/shared/item-exit-overlay.d.ts.map +1 -1
- package/build-types/shared/resize-handle.d.ts +0 -3
- package/build-types/shared/resize-handle.d.ts.map +1 -1
- package/build-types/shared/types.d.ts +0 -3
- package/build-types/shared/types.d.ts.map +1 -1
- package/build-types/shared/use-item-exit-animation.d.ts +0 -3
- package/build-types/shared/use-item-exit-animation.d.ts.map +1 -1
- package/build-types/shared/use-layout-shift-animation.d.ts.map +1 -1
- package/package.json +8 -8
- package/src/dashboard-grid/grid-item.tsx +0 -11
- package/src/dashboard-grid/index.tsx +0 -11
- package/src/dashboard-grid/resolve-fill-widths.ts +0 -3
- package/src/dashboard-grid/stories/index.story.tsx +0 -11
- package/src/dashboard-grid/test/keyboard-activation.test.tsx +0 -7
- package/src/dashboard-grid/test/resolve-fill-widths.test.ts +0 -3
- package/src/dashboard-grid/types.ts +0 -3
- package/src/dashboard-lanes/index.tsx +0 -11
- package/src/dashboard-lanes/lanes-item.tsx +0 -11
- package/src/dashboard-lanes/stories/index.story.tsx +0 -11
- package/src/dashboard-lanes/test/keyboard-activation.test.tsx +0 -7
- package/src/dashboard-lanes/test/lane-placement.test.ts +0 -3
- package/src/dashboard-lanes/test/use-lane-placement.test.tsx +0 -11
- package/src/dashboard-lanes/types.ts +0 -3
- package/src/dashboard-lanes/use-lane-placement.ts +0 -7
- package/src/shared/drag-overlay-drop-animation.ts +0 -3
- package/src/shared/grid-overlay.tsx +0 -11
- package/src/shared/item-exit-overlay.tsx +0 -3
- package/src/shared/resize-handle.tsx +0 -11
- package/src/shared/types.ts +0 -3
- package/src/shared/use-item-exit-animation.ts +0 -7
- package/src/shared/use-layout-shift-animation.ts +0 -7
|
@@ -1,16 +1,5 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* External dependencies
|
|
3
|
-
*/
|
|
4
1
|
import type { Meta, StoryObj } from '@storybook/react-vite';
|
|
5
|
-
|
|
6
|
-
/**
|
|
7
|
-
* WordPress dependencies
|
|
8
|
-
*/
|
|
9
2
|
import { useState, useMemo } from '@wordpress/element';
|
|
10
|
-
|
|
11
|
-
/**
|
|
12
|
-
* Internal dependencies
|
|
13
|
-
*/
|
|
14
3
|
import { DashboardLanes } from '..';
|
|
15
4
|
import type { DashboardLanesLayoutItem } from '../types';
|
|
16
5
|
import type { GridOverlayRenderProps } from '../../shared/types';
|
|
@@ -1,16 +1,5 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* External dependencies
|
|
3
|
-
*/
|
|
4
1
|
import { render, act, screen } from '@testing-library/react';
|
|
5
|
-
|
|
6
|
-
/**
|
|
7
|
-
* WordPress dependencies
|
|
8
|
-
*/
|
|
9
2
|
import { useState } from '@wordpress/element';
|
|
10
|
-
|
|
11
|
-
/**
|
|
12
|
-
* Internal dependencies
|
|
13
|
-
*/
|
|
14
3
|
import { GRID_ITEM_DATA_KEY } from '../../shared/grid-item-key';
|
|
15
4
|
import { useLanePlacement } from '../use-lane-placement';
|
|
16
5
|
import type {
|
|
@@ -1,11 +1,4 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* WordPress dependencies
|
|
3
|
-
*/
|
|
4
1
|
import { useState, useLayoutEffect, useMemo } from '@wordpress/element';
|
|
5
|
-
|
|
6
|
-
/**
|
|
7
|
-
* Internal dependencies
|
|
8
|
-
*/
|
|
9
2
|
import { computeLanePlacements } from './lane-placement';
|
|
10
3
|
import { GRID_ITEM_DATA_KEY } from '../shared/grid-item-key';
|
|
11
4
|
|
|
@@ -1,16 +1,5 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* External dependencies
|
|
3
|
-
*/
|
|
4
1
|
import clsx from 'clsx';
|
|
5
|
-
|
|
6
|
-
/**
|
|
7
|
-
* WordPress dependencies
|
|
8
|
-
*/
|
|
9
2
|
import { useEffect, useState } from '@wordpress/element';
|
|
10
|
-
|
|
11
|
-
/**
|
|
12
|
-
* Internal dependencies
|
|
13
|
-
*/
|
|
14
3
|
import type { GridOverlayRenderProps } from './types';
|
|
15
4
|
import styles from './grid-overlay.module.css';
|
|
16
5
|
|
|
@@ -1,19 +1,8 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* External dependencies
|
|
3
|
-
*/
|
|
4
1
|
import { DndContext, useDraggable } from '@dnd-kit/core';
|
|
5
2
|
import type { DragMoveEvent } from '@dnd-kit/core';
|
|
6
3
|
import clsx from 'clsx';
|
|
7
|
-
|
|
8
|
-
/**
|
|
9
|
-
* WordPress dependencies
|
|
10
|
-
*/
|
|
11
4
|
import { useCallback, useEffect, useRef } from '@wordpress/element';
|
|
12
5
|
import { useMergeRefs, useThrottle } from '@wordpress/compose';
|
|
13
|
-
|
|
14
|
-
/**
|
|
15
|
-
* Internal dependencies
|
|
16
|
-
*/
|
|
17
6
|
import type { ResizeDelta, ResizeHandleProps } from './types';
|
|
18
7
|
import styles from './resize-handle.module.css';
|
|
19
8
|
|
package/src/shared/types.ts
CHANGED
|
@@ -1,16 +1,9 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* WordPress dependencies
|
|
3
|
-
*/
|
|
4
1
|
import {
|
|
5
2
|
useCallback,
|
|
6
3
|
useLayoutEffect,
|
|
7
4
|
useRef,
|
|
8
5
|
useState,
|
|
9
6
|
} from '@wordpress/element';
|
|
10
|
-
|
|
11
|
-
/**
|
|
12
|
-
* Internal dependencies
|
|
13
|
-
*/
|
|
14
7
|
import type { ItemExitOverlayRect } from './item-exit-overlay';
|
|
15
8
|
import type { RectSnapshot } from './use-layout-shift-animation';
|
|
16
9
|
|
|
@@ -1,11 +1,4 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* WordPress dependencies
|
|
3
|
-
*/
|
|
4
1
|
import { useCallback, useLayoutEffect, useRef } from '@wordpress/element';
|
|
5
|
-
|
|
6
|
-
/**
|
|
7
|
-
* Internal dependencies
|
|
8
|
-
*/
|
|
9
2
|
import { GRID_ITEM_DATA_KEY } from './grid-item-key';
|
|
10
3
|
|
|
11
4
|
/* `left`/`top` are relative to the grid container, not the viewport. */
|