Browse Source

Show number of embeds when hovering the discard button

pull/46/head
coomdev 2 years ago
parent
commit
0098d0d1c9
  1. 2
      main.meta.js
  2. 10
      main.user.js
  3. 2
      src/Components/PostOptions.svelte

2
main.meta.js

@ -1,7 +1,7 @@
// ==UserScript== // ==UserScript==
// @name PNGExtraEmbed // @name PNGExtraEmbed
// @namespace https://coom.tech/ // @namespace https://coom.tech/
// @version 0.189 // @version 0.190
// @description uhh // @description uhh
// @author You // @author You
// @match https://boards.4channel.org/* // @match https://boards.4channel.org/*

10
main.user.js

@ -1,7 +1,7 @@
// ==UserScript== // ==UserScript==
// @name PNGExtraEmbed // @name PNGExtraEmbed
// @namespace https://coom.tech/ // @namespace https://coom.tech/
// @version 0.189 // @version 0.190
// @description uhh // @description uhh
// @author You // @author You
// @match https://boards.4channel.org/* // @match https://boards.4channel.org/*
@ -81,7 +81,7 @@
var define_BUILD_VERSION_default; var define_BUILD_VERSION_default;
var init_define_BUILD_VERSION = __esm({ var init_define_BUILD_VERSION = __esm({
"<define:BUILD_VERSION>"() { "<define:BUILD_VERSION>"() {
define_BUILD_VERSION_default = [0, 189]; define_BUILD_VERSION_default = [0, 190];
} }
}); });
@ -20019,6 +20019,7 @@
let i; let i;
let t_value = ctx[1].is4chanX ? "" : "\u274C"; let t_value = ctx[1].is4chanX ? "" : "\u274C";
let t; let t;
let a_title_value;
let mounted; let mounted;
let dispose; let dispose;
return { return {
@ -20027,7 +20028,7 @@
i = element("i"); i = element("i");
t = text(t_value); t = text(t_value);
attr(i, "class", "fa fa-times svelte-bgqqj3"); attr(i, "class", "fa fa-times svelte-bgqqj3");
attr(a, "title", "Discard ALL selected content"); attr(a, "title", a_title_value = "Discard ALL " + ctx[0].length + " files");
attr(a, "class", "svelte-bgqqj3"); attr(a, "class", "svelte-bgqqj3");
}, },
m(target, anchor) { m(target, anchor) {
@ -20042,6 +20043,9 @@
p(ctx2, dirty) { p(ctx2, dirty) {
if (dirty & 2 && t_value !== (t_value = ctx2[1].is4chanX ? "" : "\u274C")) if (dirty & 2 && t_value !== (t_value = ctx2[1].is4chanX ? "" : "\u274C"))
set_data(t, t_value); set_data(t, t_value);
if (dirty & 1 && a_title_value !== (a_title_value = "Discard ALL " + ctx2[0].length + " files")) {
attr(a, "title", a_title_value);
}
}, },
d(detaching) { d(detaching) {
if (detaching) if (detaching)

2
src/Components/PostOptions.svelte

@ -145,7 +145,7 @@
<!-- svelte-ignore a11y-missing-attribute --> <!-- svelte-ignore a11y-missing-attribute -->
<a <a
on:click={() => ((links = []), restore())} on:click={() => ((links = []), restore())}
title="Discard ALL selected content" title="Discard ALL {links.length} files"
> >
<i class="fa fa-times"> {$appState.is4chanX ? "" : "❌"} </i> <i class="fa fa-times"> {$appState.is4chanX ? "" : "❌"} </i>
</a> </a>

Loading…
Cancel
Save