@alexgorbatchev/shadcn 0.0.113 → 0.0.115

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.
@@ -396,6 +396,7 @@ function DataGridPagination2({ table }) {
396
396
  children: [
397
397
  /* @__PURE__ */ jsx2(OptionSelect2, {
398
398
  "aria-label": "Rows per page",
399
+ size: "sm",
399
400
  value: String(table.state.pagination.pageSize),
400
401
  onValueChange: (next) => table.setPageSize(Number(next)),
401
402
  options: [...new Set([10, 20, 50, 100, table.state.pagination.pageSize])].map((size) => ({
@@ -396,6 +396,7 @@ function Kanban2({
396
396
  children: [
397
397
  /* @__PURE__ */ jsx4(OptionSelect2, {
398
398
  "aria-label": `Move ${item.title} to`,
399
+ size: "sm",
399
400
  value: column.id,
400
401
  disabled,
401
402
  onValueChange: (next) => move(item.id, next),
@@ -7,7 +7,7 @@ import {
7
7
  DataGridColumnHeader2,
8
8
  DataGridFilter2,
9
9
  DataGridPagination2
10
- } from "../../chunk-zwns32bh.js";
10
+ } from "../../chunk-dywdx845.js";
11
11
  import"../../chunk-7ny0vyek.js";
12
12
  import"../../chunk-8ssktt4b.js";
13
13
  import"../../chunk-en44w1pn.js";
@@ -7,7 +7,7 @@ import {
7
7
  DragSource2,
8
8
  DropTarget2,
9
9
  Kanban2
10
- } from "../../chunk-jsqj1ppj.js";
10
+ } from "../../chunk-kh76d0aa.js";
11
11
  import"../../chunk-en44w1pn.js";
12
12
  import"../../chunk-dbe9ppwf.js";
13
13
  import"../../chunk-7ny0vyek.js";
@@ -100,7 +100,7 @@ import {
100
100
  TabsList2,
101
101
  TabsTrigger2,
102
102
  TabsContent2
103
- } from "../../chunk-jsqj1ppj.js";
103
+ } from "../../chunk-kh76d0aa.js";
104
104
  import"../../chunk-4e96tpw0.js";
105
105
  import {
106
106
  Checkbox2
@@ -15,6 +15,11 @@ type TreeItemState = {
15
15
  type TreeItemProps<T> = useRender.ComponentProps<"div", TreeItemState> & IDensityProps & IAnalyticsProps & {
16
16
  item: ItemInstance<T>;
17
17
  startEnhancer?: ReactNode;
18
+ /**
19
+ * Whether the row shows its kind icon (folder or file) before the label. `false` drops it and its gap, so the label
20
+ * starts where the icon was; a tree whose disclosure already tells folders from leaves needs no icon.
21
+ */
22
+ hasIcon?: boolean;
18
23
  endEnhancer?: ReactNode;
19
24
  expandOn?: "click" | "doubleClick" | "disclosure";
20
25
  isEditing?: boolean;
@@ -94,5 +99,5 @@ export declare function TreeItemDot({ count, className }: ITreeItemDotProps): Re
94
99
  * Registered tree row; compose menus with render, put counts in `description` and pointer shortcuts in `actions`.
95
100
  * `endEnhancer` holds controls that must stay keyboard reachable on their own.
96
101
  */
97
- export declare function TreeItem<T>({ analytics, item, children, startEnhancer, endEnhancer, description, descriptionLabel, actions, expandOn, isEditing, isDropTarget, isDimmed, isUnread, leading, marker, linkProps, dropHint, density, render, ref, ...props }: TreeItemProps<T>): ReactElement;
102
+ export declare function TreeItem<T>({ analytics, item, children, startEnhancer, endEnhancer, description, descriptionLabel, actions, expandOn, isEditing, isDropTarget, isDimmed, isUnread, hasIcon, leading, marker, linkProps, dropHint, density, render, ref, ...props }: TreeItemProps<T>): ReactElement;
98
103
  export type { TreeItemProps };
@@ -128,6 +128,7 @@ function TreeItem({
128
128
  isDropTarget = false,
129
129
  isDimmed = false,
130
130
  isUnread = false,
131
+ hasIcon = true,
131
132
  leading,
132
133
  marker,
133
134
  linkProps,
@@ -183,7 +184,7 @@ function TreeItem({
183
184
  const faded = isDimmed && "opacity-70 group-hover/tree-item:opacity-100 group-focus-within/tree-item:opacity-100";
184
185
  const label = /* @__PURE__ */ jsxs(Fragment, {
185
186
  children: [
186
- /* @__PURE__ */ jsx("span", {
187
+ (hasIcon || startEnhancer) && /* @__PURE__ */ jsx("span", {
187
188
  "aria-hidden": "true",
188
189
  className: "flex shrink-0 [&>svg]:size-4",
189
190
  children: startEnhancer ?? (item.isFolder() ? isExpanded ? /* @__PURE__ */ jsx(FolderOpenIcon, {}) : /* @__PURE__ */ jsx(FolderIcon, {}) : /* @__PURE__ */ jsx(FileIcon, {}))
@@ -10,7 +10,7 @@ import {
10
10
  DataGridHeaderRows,
11
11
  DataGridCells2,
12
12
  DataGridColumns
13
- } from "../../chunk-zwns32bh.js";
13
+ } from "../../chunk-dywdx845.js";
14
14
  import"../../chunk-7ny0vyek.js";
15
15
  import"../../chunk-8ssktt4b.js";
16
16
  import"../../chunk-e6hk39ev.js";
package/dist/index.js CHANGED
@@ -214,7 +214,7 @@ import {
214
214
  useDropTarget2,
215
215
  DropTarget2,
216
216
  Kanban2
217
- } from "./chunk-jsqj1ppj.js";
217
+ } from "./chunk-kh76d0aa.js";
218
218
  import {
219
219
  NumberField2,
220
220
  NumberFieldGroup2,
package/dist/prototype.js CHANGED
@@ -2051,7 +2051,7 @@ var program = new Command;
2051
2051
  // package.json
2052
2052
  var package_default = {
2053
2053
  name: "@alexgorbatchev/shadcn",
2054
- version: "0.0.113",
2054
+ version: "0.0.115",
2055
2055
  description: "Sharp, monospace React components with compact and comfortable densities.",
2056
2056
  license: "MIT",
2057
2057
  repository: {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@alexgorbatchev/shadcn",
3
- "version": "0.0.113",
3
+ "version": "0.0.115",
4
4
  "description": "Sharp, monospace React components with compact and comfortable densities.",
5
5
  "license": "MIT",
6
6
  "repository": {