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

@semcore/scroll-area

Package Overview
Dependencies
Maintainers
1
Versions
295
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@semcore/scroll-area - npm Package Compare versions

Comparing version 2.2.2 to 2.2.3

14

CHANGELOG.md

@@ -5,2 +5,10 @@ # Changelog

## [2.2.3] - 2019-10-11
### Change
- Обновлены версии пакетов
- Убран `root-ref` пакет
## [2.2.2] - 2019-10-03

@@ -21,3 +29,3 @@

### Change
### Changed

@@ -32,3 +40,3 @@ - Изменен алгоритм апдейта перерасчета с `MutationObserver` на `ResizeObserver`

### Change
### Changed

@@ -51,3 +59,3 @@ - Нужные зависимости перенесены в `utils`, размер должен стать меньше

### Change
### Changed

@@ -54,0 +62,0 @@ - Полнята версия React до 16.6 для использования contextType

@@ -10,3 +10,2 @@ import _objectWithoutProperties from '@babel/runtime/helpers/objectWithoutProperties';

import ResizeObserver from 'resize-observer-polyfill';
import RootRef from '@semcore/root-ref';
import { Box } from '@semcore/flex-box';

@@ -36,8 +35,2 @@ import EventEmitter from '@semcore/utils/lib/eventEmitter';

var data = {
"block": {
"block": "_scroll-area_1xfz5_3"
}
};
(function cssModulesFnInject(_path) {

@@ -47,9 +40,10 @@ if (_path && typeof window !== 'undefined') {

var prevStyle = head.querySelector('._css-style');
var css = "._scroll-area_111j5_3{position:relative;overflow:hidden;width:100%;height:100%}";
if (prevStyle && prevStyle.insertAdjacentText) {
prevStyle.insertAdjacentText("beforeend", "._scroll-area_1xfz5_3{position:relative;overflow:hidden;width:100%;height:100%}");
prevStyle.insertAdjacentText("beforeend", css);
} else {
var style = window.document.createElement("style");
style.classList.add('_css-style');
style.innerHTML = "._scroll-area_1xfz5_3{position:relative;overflow:hidden;width:100%;height:100%}";
style.innerHTML = css;
head.appendChild(style);

@@ -61,3 +55,3 @@ }

function block() {
return data['block']['block'];
return '_scroll-area_111j5_3';
}

@@ -207,7 +201,6 @@

}
}, React.createElement(RootRef, {
rootRef: this.refWrapper
}, React.createElement(Box, Object.assign({
ref: this.refWrapper,
className: cn(block(), className)
}, other), children)));
}, other), children));
}

@@ -221,17 +214,2 @@ }]);

var data$1 = {
"block": {
"block": "_scroll-container_a61t2_3",
"horizontal": {
"block": "_scroll-container--horizontal_a61t2_23"
},
"vertical": {
"block": "_scroll-container--vertical_a61t2_27"
}
},
"padding": {
"block": "_scroll-container__padding_a61t2_20"
}
};
(function cssModulesFnInject(_path) {

@@ -241,9 +219,10 @@ if (_path && typeof window !== 'undefined') {

var prevStyle = head.querySelector('._css-style');
var css = "._scroll-container_qpp88_3{display:block;width:100%;height:100%;box-sizing:content-box;-webkit-overflow-scrolling:touch;scrollbar-width:none;-ms-overflow-style:none}._scroll-container_qpp88_3::-webkit-scrollbar{display:none}._scroll-container--horizontal_qpp88_23{overflow-x:scroll}._scroll-container--vertical_qpp88_27{overflow-y:scroll}._scroll-container--horizontal_qpp88_23 ._scroll-container__padding_qpp88_20{display:inline-block}";
if (prevStyle && prevStyle.insertAdjacentText) {
prevStyle.insertAdjacentText("beforeend", "._scroll-container_a61t2_3{display:block;width:100%;height:100%;box-sizing:content-box;-webkit-overflow-scrolling:touch;scrollbar-width:none;-ms-overflow-style:none}._scroll-container_a61t2_3::-webkit-scrollbar{display:none}._scroll-container--horizontal_a61t2_23{overflow-x:scroll}._scroll-container--vertical_a61t2_27{overflow-y:scroll}._scroll-container--horizontal_a61t2_23 ._scroll-container__padding_a61t2_20{display:inline-block}");
prevStyle.insertAdjacentText("beforeend", css);
} else {
var style = window.document.createElement("style");
style.classList.add('_css-style');
style.innerHTML = "._scroll-container_a61t2_3{display:block;width:100%;height:100%;box-sizing:content-box;-webkit-overflow-scrolling:touch;scrollbar-width:none;-ms-overflow-style:none}._scroll-container_a61t2_3::-webkit-scrollbar{display:none}._scroll-container--horizontal_a61t2_23{overflow-x:scroll}._scroll-container--vertical_a61t2_27{overflow-y:scroll}._scroll-container--horizontal_a61t2_23 ._scroll-container__padding_a61t2_20{display:inline-block}";
style.innerHTML = css;
head.appendChild(style);

@@ -255,17 +234,15 @@ }

function block$1() {
return data$1['block']['block'];
return '_scroll-container_qpp88_3';
}
block$1['horizontal'] = function () {
var value = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : 'block';
return data$1['block']['horizontal'][value];
block$1['horizontal'] = function (value) {
return "_scroll-container--horizontal_qpp88_23";
};
block$1['vertical'] = function () {
var value = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : 'block';
return data$1['block']['vertical'][value];
block$1['vertical'] = function (value) {
return "_scroll-container--vertical_qpp88_27";
};
function padding() {
return data$1['padding']['block'];
return '_scroll-container__padding_qpp88_20';
}

@@ -347,5 +324,4 @@

var handleScrollContainer = _ref.handleScrollContainer;
return React.createElement(RootRef, {
rootRef: _this2.refContainer
}, React.createElement(Box, Object.assign({
return React.createElement(Box, Object.assign({
ref: _this2.refContainer,
className: cn(block$1(), className),

@@ -356,3 +332,3 @@ onScroll: callAllEventHandlers(onScroll, handleScrollContainer)

ref: _this2.refPadding
}, children)));
}, children));
});

@@ -368,21 +344,2 @@ }

var data$2 = {
"block": {
"block": "_scroll-bar_qrbal_3",
"hide": {
"block": "_scroll-bar--hide_qrbal_8"
},
"orientation": {
"vertical": "_scroll-bar--orientation_vertical_qrbal_12",
"horizontal": "_scroll-bar--orientation_horizontal_qrbal_20"
}
},
"slider": {
"block": "_scroll-bar__slider_qrbal_28",
"theme": {
"default": "_scroll-bar__slider--theme_default_qrbal_34"
}
}
};
(function cssModulesFnInject(_path) {

@@ -392,9 +349,10 @@ if (_path && typeof window !== 'undefined') {

var prevStyle = head.querySelector('._css-style');
var css = "._scroll-bar_1tbgv_3{position:absolute;display:-webkit-box;display:flex}._scroll-bar--hide_1tbgv_8{display:none}._scroll-bar--orientation_vertical_1tbgv_12{top:4px;right:0;width:8px;height:calc(100% - 8px);-webkit-box-pack:center;justify-content:center}._scroll-bar--orientation_horizontal_1tbgv_20{bottom:0;left:4px;height:12px;width:calc(100% - 8px);-webkit-box-align:center;align-items:center}._scroll-bar__slider_1tbgv_28{cursor:pointer;width:6px;height:6px}._scroll-bar__slider--theme_default_1tbgv_34{border-radius:2px;background-color:rgba(0,0,0,.2)}";
if (prevStyle && prevStyle.insertAdjacentText) {
prevStyle.insertAdjacentText("beforeend", "._scroll-bar_qrbal_3{position:absolute;display:-webkit-box;display:flex}._scroll-bar--hide_qrbal_8{display:none}._scroll-bar--orientation_vertical_qrbal_12{top:4px;right:0;width:8px;height:calc(100% - 8px);-webkit-box-pack:center;justify-content:center}._scroll-bar--orientation_horizontal_qrbal_20{bottom:0;left:4px;height:12px;width:calc(100% - 8px);-webkit-box-align:center;align-items:center}._scroll-bar__slider_qrbal_28{cursor:pointer;width:6px;height:6px}._scroll-bar__slider--theme_default_qrbal_34{border-radius:2px;background-color:rgba(0,0,0,.2)}");
prevStyle.insertAdjacentText("beforeend", css);
} else {
var style = window.document.createElement("style");
style.classList.add('_css-style');
style.innerHTML = "._scroll-bar_qrbal_3{position:absolute;display:-webkit-box;display:flex}._scroll-bar--hide_qrbal_8{display:none}._scroll-bar--orientation_vertical_qrbal_12{top:4px;right:0;width:8px;height:calc(100% - 8px);-webkit-box-pack:center;justify-content:center}._scroll-bar--orientation_horizontal_qrbal_20{bottom:0;left:4px;height:12px;width:calc(100% - 8px);-webkit-box-align:center;align-items:center}._scroll-bar__slider_qrbal_28{cursor:pointer;width:6px;height:6px}._scroll-bar__slider--theme_default_qrbal_34{border-radius:2px;background-color:rgba(0,0,0,.2)}";
style.innerHTML = css;
head.appendChild(style);

@@ -406,22 +364,24 @@ }

function block$2() {
return data$2['block']['block'];
return '_scroll-bar_1tbgv_3';
}
block$2['hide'] = function () {
var value = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : 'block';
return data$2['block']['hide'][value];
block$2['hide'] = function (value) {
return "_scroll-bar--hide_1tbgv_8";
};
block$2['orientation'] = function () {
var value = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : 'block';
return data$2['block']['orientation'][value];
block$2['orientation'] = function (value) {
return {
"vertical": "_scroll-bar--orientation_vertical_1tbgv_12",
"horizontal": "_scroll-bar--orientation_horizontal_1tbgv_20"
}[value];
};
function slider() {
return data$2['slider']['block'];
return '_scroll-bar__slider_1tbgv_28';
}
slider['theme'] = function () {
var value = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : 'block';
return data$2['slider']['theme'][value];
slider['theme'] = function (value) {
return {
"default": "_scroll-bar__slider--theme_default_1tbgv_34"
}[value];
};

@@ -461,5 +421,4 @@

onMouseDownSlider = _ref.onMouseDownSlider;
return React.createElement(RootRef, {
rootRef: refSlider
}, React.createElement(Box, Object.assign({
return React.createElement(Box, Object.assign({
ref: refSlider,
onDragStart: function onDragStart() {

@@ -470,3 +429,3 @@ return false;

onMouseDown: callAllEventHandlers(onMouseDown, onMouseDownSlider)
}, other)));
}, other));
});

@@ -763,8 +722,7 @@ }

value: context
}, React.createElement(RootRef, {
rootRef: this.refBar
}, React.createElement(Box, Object.assign({
ref: this.refBar,
className: classes,
onMouseDown: callAllEventHandlers(onMouseDown, this.handleMouseDownBar)
}, other), children)));
}, other), children));
}

@@ -771,0 +729,0 @@ }]);

@@ -17,3 +17,2 @@ 'use strict';

var ResizeObserver = _interopDefault(require('resize-observer-polyfill'));
var RootRef = _interopDefault(require('@semcore/root-ref'));
var flexBox = require('@semcore/flex-box');

@@ -42,8 +41,2 @@ var EventEmitter = _interopDefault(require('@semcore/utils/lib/eventEmitter'));

var data = {
"block": {
"block": "_scroll-area_1xfz5_3"
}
};
(function cssModulesFnInject(_path) {

@@ -53,9 +46,10 @@ if (_path && typeof window !== 'undefined') {

var prevStyle = head.querySelector('._css-style');
var css = "._scroll-area_111j5_3{position:relative;overflow:hidden;width:100%;height:100%}";
if (prevStyle && prevStyle.insertAdjacentText) {
prevStyle.insertAdjacentText("beforeend", "._scroll-area_1xfz5_3{position:relative;overflow:hidden;width:100%;height:100%}");
prevStyle.insertAdjacentText("beforeend", css);
} else {
var style = window.document.createElement("style");
style.classList.add('_css-style');
style.innerHTML = "._scroll-area_1xfz5_3{position:relative;overflow:hidden;width:100%;height:100%}";
style.innerHTML = css;
head.appendChild(style);

@@ -67,3 +61,3 @@ }

function block() {
return data['block']['block'];
return '_scroll-area_111j5_3';
}

@@ -213,7 +207,6 @@

}
}, React__default.createElement(RootRef, {
rootRef: this.refWrapper
}, React__default.createElement(flexBox.Box, Object.assign({
ref: this.refWrapper,
className: cn(block(), className)
}, other), children)));
}, other), children));
}

@@ -227,17 +220,2 @@ }]);

var data$1 = {
"block": {
"block": "_scroll-container_a61t2_3",
"horizontal": {
"block": "_scroll-container--horizontal_a61t2_23"
},
"vertical": {
"block": "_scroll-container--vertical_a61t2_27"
}
},
"padding": {
"block": "_scroll-container__padding_a61t2_20"
}
};
(function cssModulesFnInject(_path) {

@@ -247,9 +225,10 @@ if (_path && typeof window !== 'undefined') {

var prevStyle = head.querySelector('._css-style');
var css = "._scroll-container_qpp88_3{display:block;width:100%;height:100%;box-sizing:content-box;-webkit-overflow-scrolling:touch;scrollbar-width:none;-ms-overflow-style:none}._scroll-container_qpp88_3::-webkit-scrollbar{display:none}._scroll-container--horizontal_qpp88_23{overflow-x:scroll}._scroll-container--vertical_qpp88_27{overflow-y:scroll}._scroll-container--horizontal_qpp88_23 ._scroll-container__padding_qpp88_20{display:inline-block}";
if (prevStyle && prevStyle.insertAdjacentText) {
prevStyle.insertAdjacentText("beforeend", "._scroll-container_a61t2_3{display:block;width:100%;height:100%;box-sizing:content-box;-webkit-overflow-scrolling:touch;scrollbar-width:none;-ms-overflow-style:none}._scroll-container_a61t2_3::-webkit-scrollbar{display:none}._scroll-container--horizontal_a61t2_23{overflow-x:scroll}._scroll-container--vertical_a61t2_27{overflow-y:scroll}._scroll-container--horizontal_a61t2_23 ._scroll-container__padding_a61t2_20{display:inline-block}");
prevStyle.insertAdjacentText("beforeend", css);
} else {
var style = window.document.createElement("style");
style.classList.add('_css-style');
style.innerHTML = "._scroll-container_a61t2_3{display:block;width:100%;height:100%;box-sizing:content-box;-webkit-overflow-scrolling:touch;scrollbar-width:none;-ms-overflow-style:none}._scroll-container_a61t2_3::-webkit-scrollbar{display:none}._scroll-container--horizontal_a61t2_23{overflow-x:scroll}._scroll-container--vertical_a61t2_27{overflow-y:scroll}._scroll-container--horizontal_a61t2_23 ._scroll-container__padding_a61t2_20{display:inline-block}";
style.innerHTML = css;
head.appendChild(style);

@@ -261,17 +240,15 @@ }

function block$1() {
return data$1['block']['block'];
return '_scroll-container_qpp88_3';
}
block$1['horizontal'] = function () {
var value = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : 'block';
return data$1['block']['horizontal'][value];
block$1['horizontal'] = function (value) {
return "_scroll-container--horizontal_qpp88_23";
};
block$1['vertical'] = function () {
var value = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : 'block';
return data$1['block']['vertical'][value];
block$1['vertical'] = function (value) {
return "_scroll-container--vertical_qpp88_27";
};
function padding() {
return data$1['padding']['block'];
return '_scroll-container__padding_qpp88_20';
}

@@ -353,5 +330,4 @@

var handleScrollContainer = _ref.handleScrollContainer;
return React__default.createElement(RootRef, {
rootRef: _this2.refContainer
}, React__default.createElement(flexBox.Box, Object.assign({
return React__default.createElement(flexBox.Box, Object.assign({
ref: _this2.refContainer,
className: cn(block$1(), className),

@@ -362,3 +338,3 @@ onScroll: assignProps.callAllEventHandlers(onScroll, handleScrollContainer)

ref: _this2.refPadding
}, children)));
}, children));
});

@@ -374,21 +350,2 @@ }

var data$2 = {
"block": {
"block": "_scroll-bar_qrbal_3",
"hide": {
"block": "_scroll-bar--hide_qrbal_8"
},
"orientation": {
"vertical": "_scroll-bar--orientation_vertical_qrbal_12",
"horizontal": "_scroll-bar--orientation_horizontal_qrbal_20"
}
},
"slider": {
"block": "_scroll-bar__slider_qrbal_28",
"theme": {
"default": "_scroll-bar__slider--theme_default_qrbal_34"
}
}
};
(function cssModulesFnInject(_path) {

@@ -398,9 +355,10 @@ if (_path && typeof window !== 'undefined') {

var prevStyle = head.querySelector('._css-style');
var css = "._scroll-bar_1tbgv_3{position:absolute;display:-webkit-box;display:flex}._scroll-bar--hide_1tbgv_8{display:none}._scroll-bar--orientation_vertical_1tbgv_12{top:4px;right:0;width:8px;height:calc(100% - 8px);-webkit-box-pack:center;justify-content:center}._scroll-bar--orientation_horizontal_1tbgv_20{bottom:0;left:4px;height:12px;width:calc(100% - 8px);-webkit-box-align:center;align-items:center}._scroll-bar__slider_1tbgv_28{cursor:pointer;width:6px;height:6px}._scroll-bar__slider--theme_default_1tbgv_34{border-radius:2px;background-color:rgba(0,0,0,.2)}";
if (prevStyle && prevStyle.insertAdjacentText) {
prevStyle.insertAdjacentText("beforeend", "._scroll-bar_qrbal_3{position:absolute;display:-webkit-box;display:flex}._scroll-bar--hide_qrbal_8{display:none}._scroll-bar--orientation_vertical_qrbal_12{top:4px;right:0;width:8px;height:calc(100% - 8px);-webkit-box-pack:center;justify-content:center}._scroll-bar--orientation_horizontal_qrbal_20{bottom:0;left:4px;height:12px;width:calc(100% - 8px);-webkit-box-align:center;align-items:center}._scroll-bar__slider_qrbal_28{cursor:pointer;width:6px;height:6px}._scroll-bar__slider--theme_default_qrbal_34{border-radius:2px;background-color:rgba(0,0,0,.2)}");
prevStyle.insertAdjacentText("beforeend", css);
} else {
var style = window.document.createElement("style");
style.classList.add('_css-style');
style.innerHTML = "._scroll-bar_qrbal_3{position:absolute;display:-webkit-box;display:flex}._scroll-bar--hide_qrbal_8{display:none}._scroll-bar--orientation_vertical_qrbal_12{top:4px;right:0;width:8px;height:calc(100% - 8px);-webkit-box-pack:center;justify-content:center}._scroll-bar--orientation_horizontal_qrbal_20{bottom:0;left:4px;height:12px;width:calc(100% - 8px);-webkit-box-align:center;align-items:center}._scroll-bar__slider_qrbal_28{cursor:pointer;width:6px;height:6px}._scroll-bar__slider--theme_default_qrbal_34{border-radius:2px;background-color:rgba(0,0,0,.2)}";
style.innerHTML = css;
head.appendChild(style);

@@ -412,22 +370,24 @@ }

function block$2() {
return data$2['block']['block'];
return '_scroll-bar_1tbgv_3';
}
block$2['hide'] = function () {
var value = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : 'block';
return data$2['block']['hide'][value];
block$2['hide'] = function (value) {
return "_scroll-bar--hide_1tbgv_8";
};
block$2['orientation'] = function () {
var value = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : 'block';
return data$2['block']['orientation'][value];
block$2['orientation'] = function (value) {
return {
"vertical": "_scroll-bar--orientation_vertical_1tbgv_12",
"horizontal": "_scroll-bar--orientation_horizontal_1tbgv_20"
}[value];
};
function slider() {
return data$2['slider']['block'];
return '_scroll-bar__slider_1tbgv_28';
}
slider['theme'] = function () {
var value = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : 'block';
return data$2['slider']['theme'][value];
slider['theme'] = function (value) {
return {
"default": "_scroll-bar__slider--theme_default_1tbgv_34"
}[value];
};

@@ -467,5 +427,4 @@

onMouseDownSlider = _ref.onMouseDownSlider;
return React__default.createElement(RootRef, {
rootRef: refSlider
}, React__default.createElement(flexBox.Box, Object.assign({
return React__default.createElement(flexBox.Box, Object.assign({
ref: refSlider,
onDragStart: function onDragStart() {

@@ -476,3 +435,3 @@ return false;

onMouseDown: assignProps.callAllEventHandlers(onMouseDown, onMouseDownSlider)
}, other)));
}, other));
});

@@ -769,8 +728,7 @@ }

value: context
}, React__default.createElement(RootRef, {
rootRef: this.refBar
}, React__default.createElement(flexBox.Box, Object.assign({
ref: this.refBar,
className: classes,
onMouseDown: assignProps.callAllEventHandlers(onMouseDown, this.handleMouseDownBar)
}, other), children)));
}, other), children));
}

@@ -777,0 +735,0 @@ }]);

{
"name": "@semcore/scroll-area",
"description": "SEMRush ScrollArea Component",
"version": "2.2.2",
"version": "2.2.3",
"main": "lib/index.js",

@@ -15,5 +15,4 @@ "module": "lib/index.es.js",

"dependencies": {
"@semcore/flex-box": "^3.1",
"@semcore/root-ref": "^1.0",
"@semcore/utils": "^3.1",
"@semcore/utils": "^3.2",
"@semcore/flex-box": "^3.2",
"resize-observer-polyfill": "^1.5"

@@ -20,0 +19,0 @@ },

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

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