Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

bobril

Package Overview
Dependencies
Maintainers
1
Versions
315
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

bobril - npm Package Compare versions

Comparing version 17.7.0 to 17.8.0

5

CHANGELOG.md
# CHANGELOG
## 17.8.0
New hooks `useIsFocused()` and `useIsMouseOver()`. They return true if any child of current component has such state.
New function `shouldBeFocusVisible()` which returns true if last user interaction was by keyboard.
## 17.7.0

@@ -4,0 +9,0 @@

2

package.json
{
"name": "bobril",
"version": "17.7.0",
"version": "17.8.0",
"description": "Component Oriented MVC Framework with virtual DOM and CSS",

@@ -5,0 +5,0 @@ "main": "index.js",

@@ -14,3 +14,6 @@ import {

preventDefault,
CommonUseIsHook,
buildUseIsHook,
} from "./core";
import { isBoolean } from "./isFunc";

@@ -313,2 +316,6 @@ import { newHashObj } from "./localHelpers";

const mouseOverHookSet = new Set<CommonUseIsHook>();
export let useIsMouseOver = buildUseIsHook(mouseOverHookSet);
function mouseEnterAndLeave(ev: IBobrilPointerEvent) {

@@ -319,2 +326,4 @@ lastMouseEv = ev;

mouseOverHookSet.forEach((v) => v.update(toPath));
bubble(node, "onMouseOver", ev);

@@ -486,3 +495,3 @@

var bustingEventNames = ["!PointerDown", "!PointerMove", "!PointerUp", "!PointerCancel", "^click"];
var bustingEventNames = ["!PointerDown", "!PointerMove", "!PointerUp", "!PointerCancel", "^click"] as const;
var bustingEventHandlers = [

@@ -610,1 +619,17 @@ bustingPointerDown,

};
let lastInteractionWasKeyboard = false;
addEvent(bustingEventNames[0], 2, () => {
lastInteractionWasKeyboard = false;
return false;
});
addEvent("keydown", 2, () => {
lastInteractionWasKeyboard = true;
return false;
});
export function shouldBeFocusVisible() {
return lastInteractionWasKeyboard;
}

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is too big to display

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc