Merge branch 'master' of https://github.com/ajayyy/SponsorBlock into improvements

This commit is contained in:
Ajay Ramachandran
2021-06-18 00:46:55 -04:00
23 changed files with 482 additions and 848 deletions

View File

@@ -24,8 +24,8 @@ class CategorySkipOptionsComponent extends React.Component<CategorySkipOptionsPr
// Setup state
this.state = {
color: props.defaultColor || Config.config.barTypes[this.props.category].color,
previewColor: props.defaultPreviewColor || Config.config.barTypes["preview-" + this.props.category].color,
color: props.defaultColor || Config.config.barTypes[this.props.category]?.color,
previewColor: props.defaultPreviewColor || Config.config.barTypes["preview-" + this.props.category]?.color,
}
}
@@ -59,7 +59,8 @@ class CategorySkipOptionsComponent extends React.Component<CategorySkipOptionsPr
{chrome.i18n.getMessage("category_" + this.props.category)}
</td>
<td id={this.props.category + "SkipOption"}>
<td id={this.props.category + "SkipOption"}
className="skipOption">
<select
className="categoryOptionsSelector"
defaultValue={defaultOption}
@@ -68,7 +69,8 @@ class CategorySkipOptionsComponent extends React.Component<CategorySkipOptionsPr
</select>
</td>
<td id={this.props.category + "ColorOption"}>
<td id={this.props.category + "ColorOption"}
className="colorOption">
<input
className="categoryColorTextBox option-text-box"
type="color"
@@ -76,7 +78,8 @@ class CategorySkipOptionsComponent extends React.Component<CategorySkipOptionsPr
value={this.state.color} />
</td>
<td id={this.props.category + "PreviewColorOption"}>
<td id={this.props.category + "PreviewColorOption"}
className="previewColorOption">
<input
className="categoryColorTextBox option-text-box"
type="color"