@sentry-internal/feedback
Advanced tools
Comparing version 0.0.1-alpha.1 to 0.0.1-alpha.2
@@ -431,3 +431,2 @@ Object.defineProperty(exports, '__esModule', { value: true }); | ||
const style = d.createElement('style'); | ||
const theme = colorScheme === 'system' ? themes.light : themes[colorScheme]; | ||
style.textContent = ` | ||
@@ -449,12 +448,13 @@ :host { | ||
font-family: ${theme.fontFamily}; | ||
font-size: ${theme.fontSize}; | ||
--bg-color: ${theme.background}; | ||
--bg-hover-color: ${theme.backgroundHover}; | ||
--fg-color: ${theme.foreground}; | ||
--error-color: ${theme.error}; | ||
--success-color: ${theme.success}; | ||
--border: ${theme.border}; | ||
--box-shadow: ${theme.boxShadow}; | ||
font-family: ${themes.light.fontFamily}; | ||
font-size: ${themes.light.fontSize}; | ||
--bg-color: ${themes.light.background}; | ||
--bg-hover-color: ${themes.light.backgroundHover}; | ||
--fg-color: ${themes.light.foreground}; | ||
--error-color: ${themes.light.error}; | ||
--success-color: ${themes.light.success}; | ||
--border: ${themes.light.border}; | ||
--box-shadow: ${themes.light.boxShadow}; | ||
} | ||
${ | ||
@@ -475,3 +475,15 @@ colorScheme === 'system' | ||
` | ||
: '' | ||
: ` | ||
:host-context([data-sentry-feedback-colorscheme="dark"]) { | ||
font-family: ${themes.dark.fontFamily}; | ||
font-size: ${themes.dark.fontSize}; | ||
--bg-color: ${themes.dark.background}; | ||
--bg-hover-color: ${themes.dark.backgroundHover}; | ||
--fg-color: ${themes.dark.foreground}; | ||
--error-color: ${themes.dark.error}; | ||
--success-color: ${themes.dark.success}; | ||
--border: ${themes.dark.border}; | ||
--box-shadow: ${themes.dark.boxShadow}; | ||
} | ||
` | ||
}`; | ||
@@ -1619,2 +1631,5 @@ | ||
// set data attribute on host for different themes | ||
this._host.dataset.sentryFeedbackColorscheme = options.colorScheme; | ||
const result = cb([this._shadow, this._host]); | ||
@@ -1621,0 +1636,0 @@ |
@@ -429,3 +429,2 @@ import { prepareEvent, getCurrentHub } from '@sentry/core'; | ||
const style = d.createElement('style'); | ||
const theme = colorScheme === 'system' ? themes.light : themes[colorScheme]; | ||
style.textContent = ` | ||
@@ -447,12 +446,13 @@ :host { | ||
font-family: ${theme.fontFamily}; | ||
font-size: ${theme.fontSize}; | ||
--bg-color: ${theme.background}; | ||
--bg-hover-color: ${theme.backgroundHover}; | ||
--fg-color: ${theme.foreground}; | ||
--error-color: ${theme.error}; | ||
--success-color: ${theme.success}; | ||
--border: ${theme.border}; | ||
--box-shadow: ${theme.boxShadow}; | ||
font-family: ${themes.light.fontFamily}; | ||
font-size: ${themes.light.fontSize}; | ||
--bg-color: ${themes.light.background}; | ||
--bg-hover-color: ${themes.light.backgroundHover}; | ||
--fg-color: ${themes.light.foreground}; | ||
--error-color: ${themes.light.error}; | ||
--success-color: ${themes.light.success}; | ||
--border: ${themes.light.border}; | ||
--box-shadow: ${themes.light.boxShadow}; | ||
} | ||
${ | ||
@@ -473,3 +473,15 @@ colorScheme === 'system' | ||
` | ||
: '' | ||
: ` | ||
:host-context([data-sentry-feedback-colorscheme="dark"]) { | ||
font-family: ${themes.dark.fontFamily}; | ||
font-size: ${themes.dark.fontSize}; | ||
--bg-color: ${themes.dark.background}; | ||
--bg-hover-color: ${themes.dark.backgroundHover}; | ||
--fg-color: ${themes.dark.foreground}; | ||
--error-color: ${themes.dark.error}; | ||
--success-color: ${themes.dark.success}; | ||
--border: ${themes.dark.border}; | ||
--box-shadow: ${themes.dark.boxShadow}; | ||
} | ||
` | ||
}`; | ||
@@ -1617,2 +1629,5 @@ | ||
// set data attribute on host for different themes | ||
this._host.dataset.sentryFeedbackColorscheme = options.colorScheme; | ||
const result = cb([this._shadow, this._host]); | ||
@@ -1619,0 +1634,0 @@ |
{ | ||
"name": "@sentry-internal/feedback", | ||
"version": "0.0.1-alpha.1", | ||
"version": "0.0.1-alpha.2", | ||
"description": "Sentry SDK integration for user feedback", | ||
@@ -5,0 +5,0 @@ "repository": "git://github.com/getsentry/sentry-javascript.git", |
@@ -322,2 +322,5 @@ import type { Integration } from '@sentry/types'; | ||
// set data attribute on host for different themes | ||
this._host.dataset.sentryFeedbackColorscheme = options.colorScheme; | ||
const result = cb([this._shadow, this._host]); | ||
@@ -324,0 +327,0 @@ |
@@ -12,3 +12,2 @@ import type { FeedbackThemes } from '../types'; | ||
const style = d.createElement('style'); | ||
const theme = colorScheme === 'system' ? themes.light : themes[colorScheme]; | ||
style.textContent = ` | ||
@@ -30,12 +29,13 @@ :host { | ||
font-family: ${theme.fontFamily}; | ||
font-size: ${theme.fontSize}; | ||
--bg-color: ${theme.background}; | ||
--bg-hover-color: ${theme.backgroundHover}; | ||
--fg-color: ${theme.foreground}; | ||
--error-color: ${theme.error}; | ||
--success-color: ${theme.success}; | ||
--border: ${theme.border}; | ||
--box-shadow: ${theme.boxShadow}; | ||
font-family: ${themes.light.fontFamily}; | ||
font-size: ${themes.light.fontSize}; | ||
--bg-color: ${themes.light.background}; | ||
--bg-hover-color: ${themes.light.backgroundHover}; | ||
--fg-color: ${themes.light.foreground}; | ||
--error-color: ${themes.light.error}; | ||
--success-color: ${themes.light.success}; | ||
--border: ${themes.light.border}; | ||
--box-shadow: ${themes.light.boxShadow}; | ||
} | ||
${ | ||
@@ -56,3 +56,15 @@ colorScheme === 'system' | ||
` | ||
: '' | ||
: ` | ||
:host-context([data-sentry-feedback-colorscheme="dark"]) { | ||
font-family: ${themes.dark.fontFamily}; | ||
font-size: ${themes.dark.fontSize}; | ||
--bg-color: ${themes.dark.background}; | ||
--bg-hover-color: ${themes.dark.backgroundHover}; | ||
--fg-color: ${themes.dark.foreground}; | ||
--error-color: ${themes.dark.error}; | ||
--success-color: ${themes.dark.success}; | ||
--border: ${themes.dark.border}; | ||
--box-shadow: ${themes.dark.boxShadow}; | ||
} | ||
` | ||
}`; | ||
@@ -59,0 +71,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
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
354920
6110