storybook-addon-outline
Advanced tools
Comparing version 1.3.1 to 1.3.2
@@ -0,1 +1,13 @@ | ||
# v1.3.2 (Wed Jun 02 2021) | ||
#### ⚠️ Pushed to `main` | ||
- remove globals reference in helpers ([@winkerVSbecks](https://github.com/winkerVSbecks)) | ||
#### Authors: 1 | ||
- Varun Vachhar ([@winkerVSbecks](https://github.com/winkerVSbecks)) | ||
--- | ||
# v1.3.1 (Tue Jun 01 2021) | ||
@@ -2,0 +14,0 @@ |
@@ -8,4 +8,2 @@ "use strict"; | ||
var _global = require("global"); | ||
var clearStyles = function clearStyles(selector) { | ||
@@ -19,3 +17,3 @@ var selectors = Array.isArray(selector) ? selector : [selector]; | ||
var clearStyle = function clearStyle(selector) { | ||
var element = _global.document.getElementById(selector); | ||
var element = document.getElementById(selector); | ||
@@ -28,3 +26,3 @@ if (element && element.parentElement) { | ||
var addOutlineStyles = function addOutlineStyles(selector, css) { | ||
var existingStyle = _global.document.getElementById(selector); | ||
var existingStyle = document.getElementById(selector); | ||
@@ -36,8 +34,6 @@ if (existingStyle) { | ||
} else { | ||
var style = _global.document.createElement('style'); | ||
var style = document.createElement('style'); | ||
style.setAttribute('id', selector); | ||
style.innerHTML = css; | ||
_global.document.head.appendChild(style); | ||
document.head.appendChild(style); | ||
} | ||
@@ -44,0 +40,0 @@ }; |
{ | ||
"name": "storybook-addon-outline", | ||
"version": "1.3.1", | ||
"version": "1.3.2", | ||
"description": "Outline all elements with CSS to help with layout placement and alignment", | ||
@@ -5,0 +5,0 @@ "repository": { |
25117
199