Skip to content

Commit 699d44b

Browse files
authored
Merge pull request #142 from patuwwy/fix-bb-no-comments
No BB buttons attaching if no comment area exists
2 parents 45f1793 + f1c5b8f commit 699d44b

File tree

2 files changed

+6
-2
lines changed

2 files changed

+6
-2
lines changed

app/add-ons/shadertoy-plugin-bbcode.js

+5-1
Original file line numberDiff line numberDiff line change
@@ -120,6 +120,10 @@ position: absolute;
120120
transform: translate(4px, calc(-100% - 4px));`;
121121
textArea = document.getElementById('commentTextArea');
122122

123+
if (!textArea) {
124+
return;
125+
}
126+
123127
function createList(icon, elems) {
124128
const wrapper = document.createElement('button');
125129
wrapper.type = 'button';
@@ -307,7 +311,7 @@ function commentCodeHighlighting() {
307311
.copy-button:focus {
308312
outline: none;
309313
}
310-
314+
311315
`;
312316
var style = document.createElement('style');
313317

app/manifest.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
{
22
"manifest_version": 2,
33
"name": "Shadertoy unofficial plugin.",
4-
"version": "0.13.241",
4+
"version": "0.13.242",
55
"description": "Shadertoy.com unofficial plugin.",
66
"homepage_url": "https://github.com/patuwwy/ShaderToy-Chrome-Plugin",
77
"background": {

0 commit comments

Comments
 (0)