@asymmetric-effort/specifyjs 0.1.1 → 0.1.9
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/dist/specifyjs-components.cjs.js +1 -1
- package/dist/specifyjs-components.cjs.js.map +1 -1
- package/dist/specifyjs-components.d.ts +92 -6
- package/dist/specifyjs-components.esm.js +1 -1
- package/dist/specifyjs-components.esm.js.map +1 -1
- package/dist/specifyjs-dom.cjs.js +1 -1
- package/dist/specifyjs-dom.cjs.js.map +1 -1
- package/dist/specifyjs-dom.esm.js +1 -1
- package/dist/specifyjs-dom.esm.js.map +1 -1
- package/package.json +3 -3
|
@@ -1330,13 +1330,13 @@ interface ToolbarItem {
|
|
|
1330
1330
|
label?: string;
|
|
1331
1331
|
/** Icon text (emoji or character) */
|
|
1332
1332
|
icon?: string;
|
|
1333
|
-
/** Item type */
|
|
1334
|
-
type: 'button' | 'separator' | 'dropdown' | 'spacer';
|
|
1333
|
+
/** Item type — 'button' has momentary press, 'toggle' stays pressed until clicked again */
|
|
1334
|
+
type: 'button' | 'toggle' | 'separator' | 'dropdown' | 'spacer';
|
|
1335
1335
|
/** Click handler */
|
|
1336
1336
|
onClick?: () => void;
|
|
1337
1337
|
/** Whether the item is disabled */
|
|
1338
1338
|
disabled?: boolean;
|
|
1339
|
-
/** Whether the item is in an active/pressed state */
|
|
1339
|
+
/** Whether the item is in an active/pressed state (used by toggle) */
|
|
1340
1340
|
active?: boolean;
|
|
1341
1341
|
}
|
|
1342
1342
|
type ToolbarSize = 'sm' | 'md' | 'lg';
|
|
@@ -1697,8 +1697,18 @@ interface CartesianGraph2DProps {
|
|
|
1697
1697
|
x: number;
|
|
1698
1698
|
y: number;
|
|
1699
1699
|
}[];
|
|
1700
|
+
/** Function to plot: f(x) → y */
|
|
1700
1701
|
plotFunction?: (x: number) => number;
|
|
1702
|
+
/** Number of samples across the x range (default: 200). Ignored if xStep is set. */
|
|
1701
1703
|
plotResolution?: number;
|
|
1704
|
+
/** Explicit step increment for function evaluation (e.g., 0.1).
|
|
1705
|
+
* When set, overrides plotResolution and computes f(x) at
|
|
1706
|
+
* x = xRange[0], xRange[0]+step, xRange[0]+2*step, ..., xRange[1]. */
|
|
1707
|
+
xStep?: number;
|
|
1708
|
+
/** If true, compute plotFunction synchronously (blocks render).
|
|
1709
|
+
* Default: false — computes asynchronously via requestIdleCallback,
|
|
1710
|
+
* rendering progressively as results arrive. */
|
|
1711
|
+
sync?: boolean;
|
|
1702
1712
|
xRange?: [number, number];
|
|
1703
1713
|
yRange?: [number, number];
|
|
1704
1714
|
showGrid?: boolean;
|
|
@@ -1727,13 +1737,26 @@ interface ComplexGraph2DProps {
|
|
|
1727
1737
|
realRange?: [number, number];
|
|
1728
1738
|
imagRange?: [number, number];
|
|
1729
1739
|
maxIterations?: number;
|
|
1730
|
-
colorScheme?:
|
|
1740
|
+
colorScheme?: "classic" | "fire" | "ocean";
|
|
1731
1741
|
computeFunction?: (re: number, im: number, maxIter: number) => number;
|
|
1742
|
+
/** Precomputed iteration grid (rows x cols). When provided, renders as SVG
|
|
1743
|
+
* instead of canvas. Each value is the iteration count at that pixel. */
|
|
1744
|
+
data?: number[][];
|
|
1745
|
+
/** Pixel resolution for precomputed SVG rendering (default: 2) */
|
|
1746
|
+
resolution?: number;
|
|
1747
|
+
/** If true, compute values synchronously (blocks render).
|
|
1748
|
+
* Default: false — uses canvas useEffect for runtime computation. */
|
|
1749
|
+
sync?: boolean;
|
|
1732
1750
|
onPointClick?: (info: ComplexPointInfo) => void;
|
|
1733
1751
|
onPointHover?: (info: ComplexPointInfo) => void;
|
|
1734
1752
|
onPointDoubleClick?: (info: ComplexPointInfo) => void;
|
|
1735
1753
|
onPointContextMenu?: (info: ComplexPointInfo) => void;
|
|
1736
1754
|
}
|
|
1755
|
+
/**
|
|
1756
|
+
* Precompute a Mandelbrot iteration grid at a given resolution.
|
|
1757
|
+
* Returns a 2D array of iteration counts (rows x cols).
|
|
1758
|
+
*/
|
|
1759
|
+
declare function computeMandelbrotGrid(cols: number, rows: number, realRange?: [number, number], imagRange?: [number, number], maxIter?: number, computeFn?: (re: number, im: number, maxIter: number) => number): number[][];
|
|
1737
1760
|
declare function ComplexGraph2D(props: ComplexGraph2DProps): specifyjs_shared_types.SpecElement<specifyjs_shared_types.Props>;
|
|
1738
1761
|
|
|
1739
1762
|
interface Point {
|
|
@@ -1890,8 +1913,17 @@ interface PolarGraph2DProps {
|
|
|
1890
1913
|
width?: number;
|
|
1891
1914
|
height?: number;
|
|
1892
1915
|
rRange?: [number, number];
|
|
1916
|
+
/** Function to plot: f(theta) → r */
|
|
1893
1917
|
plotFunction?: (theta: number) => number;
|
|
1918
|
+
/** Number of samples around the full circle (default: 360). Ignored if thetaStep is set. */
|
|
1894
1919
|
plotResolution?: number;
|
|
1920
|
+
/** Explicit step increment in radians for function evaluation (e.g., Math.PI/180).
|
|
1921
|
+
* When set, overrides plotResolution and computes f(theta) at
|
|
1922
|
+
* theta = 0, step, 2*step, ..., 2*PI. */
|
|
1923
|
+
thetaStep?: number;
|
|
1924
|
+
/** If true, compute plotFunction synchronously (blocks render).
|
|
1925
|
+
* Default: false — computes asynchronously. */
|
|
1926
|
+
sync?: boolean;
|
|
1895
1927
|
points?: {
|
|
1896
1928
|
r: number;
|
|
1897
1929
|
theta: number;
|
|
@@ -2104,5 +2136,59 @@ interface GoogleAnalyticsProps {
|
|
|
2104
2136
|
}
|
|
2105
2137
|
declare function GoogleAnalytics(props: GoogleAnalyticsProps): null;
|
|
2106
2138
|
|
|
2107
|
-
|
|
2108
|
-
|
|
2139
|
+
interface FooterProps {
|
|
2140
|
+
/** Content for the left section */
|
|
2141
|
+
left?: unknown;
|
|
2142
|
+
/** Content for the center section */
|
|
2143
|
+
center?: unknown;
|
|
2144
|
+
/** Content for the right section */
|
|
2145
|
+
right?: unknown;
|
|
2146
|
+
/** Border top style */
|
|
2147
|
+
borderTop?: string;
|
|
2148
|
+
/** Background color */
|
|
2149
|
+
background?: string;
|
|
2150
|
+
/** Text color */
|
|
2151
|
+
color?: string;
|
|
2152
|
+
/** Font size */
|
|
2153
|
+
fontSize?: string;
|
|
2154
|
+
/** Padding */
|
|
2155
|
+
padding?: string;
|
|
2156
|
+
/** Max width for inner container */
|
|
2157
|
+
maxWidth?: string;
|
|
2158
|
+
/** CSS className */
|
|
2159
|
+
className?: string;
|
|
2160
|
+
/** ARIA label for the footer landmark */
|
|
2161
|
+
ariaLabel?: string;
|
|
2162
|
+
}
|
|
2163
|
+
declare function Footer(props: FooterProps): specifyjs_shared_types.SpecElement<specifyjs_shared_types.Props>;
|
|
2164
|
+
|
|
2165
|
+
interface UnityDesktopProps {
|
|
2166
|
+
/** Content rendered in the main desktop area */
|
|
2167
|
+
children?: unknown;
|
|
2168
|
+
/** Extra class name */
|
|
2169
|
+
className?: string;
|
|
2170
|
+
}
|
|
2171
|
+
declare function UnityDesktop(props: UnityDesktopProps): specifyjs_shared_types.SpecElement<specifyjs_shared_types.Props>;
|
|
2172
|
+
|
|
2173
|
+
interface WordProcessorProps {
|
|
2174
|
+
/** Document content rendered in the page area */
|
|
2175
|
+
content?: string;
|
|
2176
|
+
/** Extra class name */
|
|
2177
|
+
className?: string;
|
|
2178
|
+
}
|
|
2179
|
+
declare function WordProcessor(props: WordProcessorProps): specifyjs_shared_types.SpecElement<specifyjs_shared_types.Props>;
|
|
2180
|
+
|
|
2181
|
+
interface IDEProps {
|
|
2182
|
+
/** Extra class name */
|
|
2183
|
+
className?: string;
|
|
2184
|
+
}
|
|
2185
|
+
declare function IDE(props: IDEProps): specifyjs_shared_types.SpecElement<specifyjs_shared_types.Props>;
|
|
2186
|
+
|
|
2187
|
+
interface TradingDashboardProps {
|
|
2188
|
+
/** Extra class name */
|
|
2189
|
+
className?: string;
|
|
2190
|
+
}
|
|
2191
|
+
declare function TradingDashboard(props: TradingDashboardProps): specifyjs_shared_types.SpecElement<specifyjs_shared_types.Props>;
|
|
2192
|
+
|
|
2193
|
+
export { Accordion, Alert, AnalogClock, Avatar, Badge, BarGraph, Breadcrumb, Card, Carousel, CartesianGraph2D, Checkbox, ColorPicker, ColorWheel, ComplexGraph2D, ContextMenu, DataGrid, DatePicker, DigitalClock, Drawer, Dropdown, EmptyState, FileUpload, FlexContainer, FlexItem, Footer, FormFieldWrapper, GoogleAnalytics, Grid, GridItem, HypercubeGraph, IDE, Image, LineGraph, ListView, Menubar, Modal, MultilineField, NavWrapper, NumberSpinner, Pagination, Panel, PieGraph, PolarGraph2D, Popover, ProgressBar, RadioGroup, ScrollContainer, Select, Sidebar, Skeleton, Slider, Spinner, Splitter, Stepper, Tabs, Tag, TextEditor, TextField, TimePicker, ToastContainer, Toggle, Toolbar, Tooltip, TradingDashboard, TreeNav, TreeNode, UnityDesktop, VideoPlayer, VirtualScroll, VizWrapper, WordProcessor, buildInputStyle, buildNavItemStyle, buildRotationMatrix, computeMandelbrotGrid, computeSlices, createToaster, describeArc, generateEdges, generateHypercube, generatePalette, generateVertices, numRotationAngles, projectTo2D, transformVec, useBarGraphScales, useHover, useHypercube, useLineGraphScales, useToast };
|
|
2194
|
+
export type { AccordionContentStyle, AccordionHeaderStyle, AccordionProps, AccordionSection, AlertProps, AnalogClockProps, AvatarProps, BadgeProps, BarDatum, BarGraphProps, BarGraphScales, BreadcrumbItem, BreadcrumbProps, BreadcrumbSize, CardProps, CarouselProps, CartesianGraph2DProps, CheckboxProps, ColorPickerProps, ColorWheelProps, ComplexGraph2DProps, ComplexPointInfo, ComputedSlice, ContextMenuItem, ContextMenuProps, DataGridColumn, DataGridProps, DatePickerProps, DigitalClockProps, DrawerPosition, DrawerProps, DropdownItem, DropdownProps, Edge, EmptyStateProps, FileUploadProps, FlexContainerProps, FlexItemProps, FooterProps, FormFieldWrapperProps, FormFieldWrapperStyle, GoogleAnalyticsProps, GridBreakpoint, GridItemProps, GridProps, HypercubeData, HypercubeGraphProps, IDEProps, ImageProps, InputBaseStyle, LegendItem, LineGraphProps, LineSeries, ListViewProps, MenuDefinition, MenuItem, MenubarProps, ModalProps, ModalSize, MultilineFieldProps, NavItemStyle, NavOrientation, NavWrapperProps, NavWrapperStyle, NumberSpinnerProps, PaginationProps, PanelProps, PieGraphProps, PieSliceDatum, Point, PointEvent, PolarGraph2DProps, PolarPointInfo, PopoverPlacement, PopoverProps, Position, ProgressBarProps, RadioGroupProps, RadioOption, ScrollContainerProps, SelectOption, SelectProps, SidebarItem, SidebarProps, SkeletonProps, SliderMark, SliderProps, SpinnerProps, SplitterProps, StackedBarDatum, StepItem, StepperOrientation, StepperProps, StepperVariant, TabDefinition, TabsProps, TagProps, TextEditorProps, TextFieldProps, TimePickerProps, ToastAction, ToastItem, ToastOptions, ToastPosition, ToastType, Toaster, ToasterConfig, ToggleProps, ToolbarButton, ToolbarItem, ToolbarProps, ToolbarSize, ToolbarVariant, TooltipPlacement, TooltipProps, TradingDashboardProps, TreeNavProps, TreeNodeData, UnityDesktopProps, UseHypercubeOptions, Vec, Vertex, VideoPlayerProps, VirtualScrollProps, VizWrapperProps, WordProcessorProps };
|