jQWidgets ver. 27.1.0
What’s New #
- Six new themes: Tailwind Blue and dark variants
tailwind-blue and tailwind-blue-dark (Tailwind with Microsoft 365’s blue accent), and fluent-dark, material-dark, material-green-dark and material-purple-dark. The library lays each dark variant out like its light theme, so sizes and spacing match when an application switches between them. New helpers $.jqx.themeFamily(), $.jqx.themeSurface() and $.jqx.themeText() let application code do the same.
- A modern look for the data widgets, in every theme
jqxGrid, jqxDataTable and jqxTreeGrid have quieter column lines, 8px cell padding, tabular digits, semibold column titles, one-line aggregates and no grey blocks in the filter row and status bar. A selected cell range is drawn as one outline instead of a box per cell. jqxPivotGrid gets chevron expanders and semibold totals, and jqxGantt takes its bar, connector, weekend and non-working colours from the theme. Row heights, options and class names are unchanged.
- A modern look for the widgets without a theme and in the design-system themes
Widgets with no theme set now use a system font, 4px corners, SVG icons and a WCAG AA colour palette, through new -base classes that jqx.base.css styles. In the base theme and the light, dark, Fluent, Tailwind and Material families, windows are rounded dialogs; the calendar draws days as circles and a range as one band; drop-downs open as rounded pop-ups with pill tokens; and the editor, kanban, toolbars, notifications, loader, rating, slider, progress bar and file upload are refreshed. Classic themes keep their look.
- jqxScheduler: year views
yearView shows the year as twelve month calendars, with coloured dots for days that have appointments (maxDots) and a tooltip listing them; clicking a day or pressing Enter opens it in the scheduler’s most detailed view. timelineYearView shows one column per day under month headers, with resources in rows. Both are fully keyboard navigable.
- jqxScheduler: undo and redo
The undoRedo property (on by default) and undoRedoLimit, the methods undo(), redo(), canUndo(), canRedo() and clearUndoRedo(), the undoRedoChange event, and Ctrl+Z, Ctrl+Y and Ctrl+Shift+Z. Adding, moving, resizing, editing and deleting appointments are recorded; an iCalendar import is one step.
- jqxScheduler: cancelable events and booking rules
New appointmentAdding, appointmentChanging and appointmentDeleting events fire before a change and can cancel it (event.cancel, event.args.cancel or return false); args.action says whether the change is an add, move, resize, edit, delete, import, undo or redo. New blockedTimes, allowOverlap, minDuration and maxDuration properties define booking rules: blocked cells are hatched and labelled, and a change that breaks a rule arrives in the “-ing” event already cancelled, with the reason, so an application can still allow it. addAppointment and deleteAppointment now return true or false.
- jqxScheduler: iCalendar import, free slots and navigation
importData(icsText) reads .ics files from Google Calendar, Outlook, Apple Calendar and Thunderbird, including time zones, recurrence rules and exceptions; a matching UID updates the existing appointment. findAvailableSlots() returns free time that respects appointments and blocked times. scrollToTime() scrolls the day and week views to a time. The toolbar has a Today button, day and week views show a current-time line, and appointmentClick and appointmentDoubleClick report the clicked occurrence of a recurring appointment.
- Time zones follow daylight saving
Time zone conversions now use the browser’s time zone data for the moment being converted, so they are right on both sides of a daylight saving change; the built-in table is used only where that data is unavailable. Zone ids also accept IANA names (‘Europe/Sofia’) and the display names Outlook writes. The table’s fixed offsets were corrected for current rules (Venezuela, Turkey, Jordan, Syria, Russia, Morocco, Namibia, Brazil, Argentina and others), and Belarus and Kaliningrad were added. New $.jqx.date.timeZoneOffset(timeZone, date).
- Dark themes in charts, gauges and drawings
Under a dark theme, jqxChart, jqxDraw, jqxGauge, jqxLinearGauge, jqxBarGauge, jqxBulletChart, jqxKnob and jqxTreeMap take the theme’s background, line, grid and text colours, and redraw when a theme stylesheet loads after the first render. Colours the application sets are kept. jqxHeatMap and jqxTreeMap labels are black or white, whichever reads better on the fill.
- jqxChart: new defaults and a colour-blind-friendly palette
Charts have no border line, flat fills, lighter grid lines and no category-axis grid lines by default, and the default colour scheme is the new scheme28, chosen to stay distinguishable for colour-blind readers, with lighter colours on dark themes. See Upgrade notes to keep the previous look. formatSettings accept suffix as well as the original sufix.
- Grid cell templates on dark themes
The built-in badge, trend, bool and tags templates get a dark palette on dark themes, and cell templates receive a fourth argument, { dark }, so custom templates can do the same.
- jqxKanban: initials avatars
A resource without an image shows its initials on a colour derived from the name, instead of a broken image.
- jqxPickList: searchMode
The filter boxes match anywhere in an item, ignoring case, by default; the new searchMode option sets another mode. Double-click moves the item under the pointer in multiple-selection mode.
- jQuery 4
The library works with jQuery 4.0 as well as 3.x and without jQuery. Uses of the APIs jQuery 4 removed ($.isFunction, $.isArray, $.trim, $.type, $.parseJSON and others) were replaced throughout, with $.jqx equivalents.
- React components
Only props whose value changed are applied to the widget again, so a re-render no longer rebinds a grid’s source, resets its sort or moves a list back to its selectedIndex. val(”), val(0) and val(false) set the value. Components survive StrictMode’s development remount, put back elements the widget moved when they unmount, bind each event once, pass aria-* and data-* props to the host element, accept children in TypeScript, and find their element even when it is rendered inside another widget’s template or a tab (previously “Invalid Selector – #Jqx…”). Event props are typed so that event.args compiles in strict mode.
- Vue 3 components
v-model works: the model is applied to the widget and update:modelValue carries the widget’s value (it was undefined), for any value type. Only changed props are applied again, components destroy their widget when unmounted, and Barcode, QRcode, Chat, CheckBoxGroup, RadioButtonGroup, SplitLayout and PivotDesigner now create their widget. jqxEditor’s slot works.
- Angular components
ngModel no longer clears a widget while the form starts up, and jqxCheckBox and jqxRadioButton apply the model’s value. Method and input types that were generated as undefined (for example setColor, most jqxGantt methods, aiApplyResolution) are now typed. jqxPickList has a searchMode input.
- TypeScript definitions
theme is now declared on the 19 widgets that lacked it (among them jqxBarGauge, jqxBulletChart, jqxChart, jqxGauge, jqxKnob, jqxPivotGrid and jqxRating), so the React and Vue components pass it to the widget. Callback parameters the library always passes are required, so renderers such as cellsrenderer compile in strict mode; optional method arguments are optional; and many types were corrected against the library, among them jqxGrid’s contextmenu options, pagenum and addrow’s commit callback, jqxNotification’s template, jqxCalendar’s titleFormat and jqxTreeMap’s renderCallbacks. New ListBoxItem and ChartRenderer interfaces, and the new jqxScheduler members.
Accessibility #
- jqxTabs
Tabs and panels publish the tab pattern (role, aria-selected, aria-controls, aria-labelledby) with a roving tabindex, including tabs added with addAt and disabled tabs; only the selected tab is a Tab stop.
- Keyboard entry into grids and trees
Tabbing into a jqxGrid or jqxTree with nothing selected and pressing an arrow key now starts at the first visible row or item of the current page and sort order. Previously the keys did nothing until a row or item was clicked.
- jqxMenu, jqxTree, jqxSlider, gauges and jqxRibbon
jqxMenu now writes aria-haspopup, aria-expanded and aria-owns (they were never set) and no longer hides the focus ring. jqxTree items with children publish aria-expanded. jqxSlider’s arrow buttons are hidden from assistive technology. jqxGauge, jqxLinearGauge and jqxBarGauge are named by their current reading, which now updates when the value changes. jqxRibbon keeps the ids the page gave its items.
- jqxScheduler
The year view publishes a grid per month with labelled, selectable days; edit dialog fields are named by their labels and rule messages are announced; appointment text colour is chosen for contrast with the theme’s real background; and focus stays on an appointment after moving or resizing it with the keyboard.
- Focus and contrast in the themes
A visible 2px focus ring (:focus-visible) in the base, light, Material and Fluent themes, checkboxes and radio buttons included. Contrast fixes in the light, dark, Bootstrap, black and metrodark themes, and dark no longer upper-cases window titles, buttons and labels.
Security #
- Strict Content-Security-Policy support
The widgets run under a policy without ‘unsafe-inline’ and ‘unsafe-eval’ in script-src and style-src. Inline styles in widget markup, including the markup of application renderers and templates, are applied through the CSSOM by the new $.jqx.csp helpers, and the <style> elements the library adds carry the page’s nonce ($.jqx.csp.nonce, <meta name=”csp-nonce”>, or the nonce of the script that loaded the library). Grid exports work under the policy. javascript: links were replaced. PDF export (pdfmake) still needs ‘unsafe-eval’.
- No eval in JSON parsing
JSON is parsed with JSON.parse only; the new Function fallback was removed.
- jqxKanban resource names are escaped
A resource name containing a quote could break out of the avatar’s alt and title attributes.
What’s Fixed #
- jqxGrid
destroy() on a grid that shares its dataAdapter (common in React and Vue) left the grid bound to the adapter, so the next grid on it threw. Switching theme at run time produced classes such as -tailwind-dark-dark and left pop-ups (pager, filter row, editors) in the old theme. updatebounddata(‘data’) lost the current sort, and a full updatebounddata() kept the old sort state. A theme forced column lines back on over showcolumnlines: false. cellselect args carry rowindex and datafield as documented. The filter row applied a filter twice when Enter was pressed. sortby() with ‘asc’/’desc’ stored the string. The column menu button showed when the menu was empty. Focus entering a nested grid selected the outer grid’s first row. Ever-present row buttons threw after a sort. A server-side filter that matched nothing (totalrecords: 0) left the previous total in the pager.
- jqxDataTable, jqxTreeGrid and jqxPivotGrid
destroy() unbinds the dataAdapter and is safe to call twice. The loading box follows the theme. Pivot values without a formatFunction no longer print a lone prefix or suffix, and destroy() removes the pivot grid’s elements from <body>.
- jqxScheduler
ICS export: non-ASCII text, free-time status, all-day appointments, recurrence rules, escaping and time zones were wrong, and exporting one file per resource never worked. setAppointmentProperty left getAppointments() stale. Drag feedback trembled or landed on the wrong row after content above the scheduler changed height. Setting width or height at run time collapsed auto-width columns. Agenda times showed no AM/PM. showAllDayRow: false laid out the first row wrongly. ensureAppointmentVisible did not work for recurring series. In RTL, the week view marked the wrong day as today. destroy() left pop-ups and a timer behind.
- Date helpers
addMonths went to the wrong year when moving back past January.
- jqxSlider and gauges
int64 sliders with ticks were broken in 27.0.0; the tick calculation is restored. int64: true is recognised on sliders and gauges, and setting min or max at run time on a 64-bit gauge works.
- More fixes
jqxTabs addAt and removeAt threw under jQuery 4, and jqxDragDrop’s handle option threw under jQuery 3 and later. jqxQRCode handles imageWidth and imageHeight given as “40px”. jqxTimeline places its dots correctly wherever it is on the page, shows dates as dates and no longer prints “undefined” for missing fields. Closing a modal jqxWindow removed other windows’ modal overlays. jqxRangeSelector with a percentage width was wider than its container. jqxNavigationBar re-fits when a theme stylesheet loads late. jqxDraw getSize() threw before anything was drawn. jqxToolbar, jqxBarGauge and jqxChart left elements and handlers behind after destroy(). jqxChat rendered without styles in 27.0.0. Theme switching with $.jqx.utilities.setTheme changed classes that merely contained the old theme name, and from no theme it suffixed the application’s own classes. Async callbacks were ignored by builds without jQuery. Globalize threw “Cannot set properties of undefined (setting ‘Globalize’)” under Vite’s dev server.
- Packages
jqwidgets-ng: component bundles imported their runtime again (production builds showed “JQXLite is not defined”), jqxPivotDesigner, jqxPickList and jqxButtons got their runtime, its typings find jqwidgets.d.ts again, and sideEffects no longer lets bundlers drop the runtime. jqwidgets-scripts: the jqxForm, jqxPivotDesigner and jqxTagCloud module bundles include their dependencies, and jqxPickList has a module bundle. The React bundles for jqxChat, jqxSplitLayout and jqxPivotDesigner, and the data widgets’ React and Vue bundles, import everything they need.
Upgrade notes #
- jqxChart looks different by default
To keep the previous look, set useGradient: true, showBorderLine: true and colorScheme: ‘scheme01’, and gridLines: { visible: true } on the category axis.
- Widgets with no theme carry -base classes
Unthemed widgets now have classes such as jqx-widget-base next to their usual classes, and look modern. CSS or tests that match exact class lists may need updating.
- Keyboard selection
The first arrow key in a jqxGrid or jqxTree with nothing selected now selects the first row or item and raises rowselect, cellselect or select. jqxTabs’ host element is no longer a Tab stop; focus() focuses the selected tab.
- jqxScheduler
appointmentDelete fires after the appointment is removed. setView(name) finds the view by name in the views list and returns true or false. toolBarRangeFormatAbbr defaults to ‘dd MMM yyyy’. The edit dialog is slightly larger. Changing timeZone at run time converts existing appointments to the new zone. The zone id ‘Hawaiteratoran Standard Time’ is now ‘Hawaiian Standard Time’ (the old id still works).
- Renamed and removed members
jqxGantt rightToLeft is rtl, jqxNumberInput autoHidePromptChart is autoHidePromptChar, and jqxRangeSelector showMajorLabels (use showGroupLabels), jqxRepeatButton toggled and jqxSplitLayout disabled were removed from the definitions. jqxButton cursor is a string, and jqxCheckBoxGroup and jqxRadioButtonGroup change is a function.
- Stricter TypeScript definitions
Code that passed jqxGrid pagenum as a string, typed addrow’s commit as a boolean, gave jqxCalendar titleFormat a string, or passed DataTable hideDetails a boolean no longer compiles; the new types match what the library does.
- React and Vue components
Props are applied again only when their value changes, so an array or object changed in place needs a new reference to reach the widget. Vue v-model components emit update:modelValue and no longer input; jqxMenu autoSizeMainItems defaults to false, as in the widget.
- jqxChat and jqxPickList
jqxChat’s colorScheme: ‘auto’ follows the page’s jQWidgets theme, falling back to the operating system. jqxPickList filters match anywhere in an item.
This entry was posted in ANGULAR, ANGULAR GRID, Grid, JavaScript, JavaScript Plugins, JavaScript UI Plugins, JavaScript UI Widgets, JavaScript Widgets, jQuery, jQuery UI, jQuery UI Plugins, jQuery UI Widgets, jqxGrid and tagged angular scheduler, dark mode data grid, dark mode scheduler, data grid, grid, react scheduler, reactjs scheduler, scheduler, tailwind css. Bookmark the permalink.
|
|