mirror of
https://github.com/qlik-oss/nebula.js.git
synced 2025-12-25 01:04:14 -05:00
Tsm/fixes (#686)
* fix: resolve console error for incomplete charts * chore: add spec clarifiction for constraints * feat: add keyboard navigation as serve option * chore: bump spec version
This commit is contained in:
@@ -3,7 +3,7 @@
|
||||
"info": {
|
||||
"name": "@nebula.js/stardust",
|
||||
"description": "Product and framework agnostic integration API for Qlik's Associative Engine",
|
||||
"version": "2.0.0",
|
||||
"version": "2.1.0",
|
||||
"license": "MIT",
|
||||
"stability": "stable"
|
||||
},
|
||||
@@ -1534,14 +1534,17 @@
|
||||
"kind": "interface",
|
||||
"entries": {
|
||||
"passive": {
|
||||
"description": "Whether or not passive constraints are on. Should block any passive interaction by users, ie: tooltips",
|
||||
"optional": true,
|
||||
"type": "boolean"
|
||||
},
|
||||
"active": {
|
||||
"description": "Whether or not active constraints are on. Should block any active interaction by users, ie: scroll, click",
|
||||
"optional": true,
|
||||
"type": "boolean"
|
||||
},
|
||||
"select": {
|
||||
"description": "Whether or not active select are on. Should block any selection action. Implied when active is true.",
|
||||
"optional": true,
|
||||
"type": "boolean"
|
||||
}
|
||||
|
||||
@@ -832,9 +832,9 @@ export function useAction(fn, deps) {
|
||||
|
||||
/**
|
||||
* @interface Constraints
|
||||
* @property {boolean=} passive
|
||||
* @property {boolean=} active
|
||||
* @property {boolean=} select
|
||||
* @property {boolean=} passive Whether or not passive constraints are on. Should block any passive interaction by users, ie: tooltips
|
||||
* @property {boolean=} active Whether or not active constraints are on. Should block any active interaction by users, ie: scroll, click
|
||||
* @property {boolean=} select Whether or not active select are on. Should block any selection action. Implied when active is true.
|
||||
*/
|
||||
|
||||
/**
|
||||
@@ -1120,7 +1120,8 @@ export function focus(component) {
|
||||
|
||||
export function blur(component) {
|
||||
const acc = component.__hooks.accessibility;
|
||||
if (!acc.active) {
|
||||
// Incomplete/Invalid/Legacy viz hasn't been initialized with hooks
|
||||
if (!acc || !acc.active) {
|
||||
return;
|
||||
}
|
||||
acc.active = false;
|
||||
|
||||
@@ -23,6 +23,7 @@ Options:
|
||||
[string] [default: "nebula.config.js"]
|
||||
--entry File entrypoint [string]
|
||||
--type Generic object type [string]
|
||||
--keyboardNavigation [boolean] [default: false]
|
||||
--build [boolean] [default: true]
|
||||
--host [string] [default: "localhost"]
|
||||
--port [number]
|
||||
|
||||
@@ -35,6 +35,10 @@ const options = {
|
||||
type: 'boolean',
|
||||
default: false,
|
||||
},
|
||||
keyboardNavigation: {
|
||||
type: 'boolean',
|
||||
default: false,
|
||||
},
|
||||
resources: {
|
||||
type: 'string',
|
||||
description: 'Path to a folder that will be served as static files under /resources',
|
||||
|
||||
@@ -135,6 +135,7 @@ module.exports = async ({
|
||||
flags: serveConfig.flags,
|
||||
themes: themes.map((theme) => theme.id),
|
||||
types: serveConfig.types,
|
||||
keyboardNavigation: serveConfig.keyboardNavigation,
|
||||
});
|
||||
});
|
||||
|
||||
|
||||
@@ -84,6 +84,7 @@ export default function App({ app, info }) {
|
||||
context: {
|
||||
theme: currentThemeName,
|
||||
language: currentLanguage,
|
||||
keyboardNavigation: info.keyboardNavigation,
|
||||
},
|
||||
load: (type) => Promise.resolve(window[type.name]),
|
||||
flags: info.flags,
|
||||
|
||||
Reference in New Issue
Block a user