",
v = "drag",
L = "edit",
K = "pick",
A = "mark",
y = ".card",
R = ".text",
m = ".tag",
E = "menu a",
f = ":has(." + A + ")",
t = ".",
M = "click",
u = "dblclick",
p = "hover",
U = "keydown",
J = "mousedown",
i = "mouseup",
N = "mousemove",
r = "contentEditable",
Q = "value",
H = "top",
w = "left",
B = "board",
z = !0 + "",
S = !1,
n = ["white", "green", "blue", "red", "orange", "yellow"],
c = new RegExp("\\b(" + n.join(")|(") + ")\\b"),
x = /^mouse(enter|over)/i,
k = {
r: function () {
if (confirm("Are you sure you want to clear all saved data?")) {
I.removeItem(B);
location.reload()
}
},
e: function (V) {
V[u]()
},
c: function (W) {
var V = W.color();
if (V) {
W.rC(V);
V = n.indexOf(V);
V = n[++V < 6 ? V : 0];
W.aC(V);
q()
}
},
d: function (V) {
if (confirm("Are you sure you want to delete this card?")) {
V.fadeOut(function () {
V.remove();
q()
})
}
},
b: function () {
d.execCommand("bold", S, "")
},
i: function () {
d.execCommand("italic", S, "")
},
h: function () {
j("p", "h2")
},
p: function () {
j("h2", "p")
}
},
a = ["Need a new card? Just grab it from a deck on the left", "Move cards around to arrange them in any way you want: todo list? kanban board?", "Double-click card to edit", "You can use hotkeys when editing text, just check
Ctrl+I or
Ctrl+B!", "Every change is immediately saved in your browser", "You've already noticed #tags, didn't you?", "
Ctrl+H makes a
Heading
and Ctrl+G turns text into a paragraph", 0, "It's not a tip... I just have some spare bytes below 10k limit ;)"],
s = G(d),
F = G(d.body),
O, b, C, o, l = -1,
T;
a[24] = "Oh, I forgot to tell you about HEX color tags #F5A";
a[42] = "Answer to life, the universe and everything is 42";
function e() {
return a[++l] ? "
" + a[l] + " #tip
" : ""
}
function j(X, W) {
if (G.browser.mozilla) {
var V = G(getSelection().anchorNode);
if (V.is(R)) {
V = V.$(X).eq(0)
} else {
V = V.up(R + " " + X)
}
V.replaceWith(function (Z, Y) {
return "<" + W + ">" + Y + "" + W + ">"
})
} else {
d.execCommand("formatblock", S, "<" + W + ">")
}
}
function D(V) {
return O.$(m).filter(function () {
return G(this).text().toLowerCase() == V.toLowerCase()
})
}
function q() {
var V = [],
W;
O.$(y).each(function () {
W = G(this);
V.push(G.extend(W.offset(), {
type: W.color(),
text: W.data(Q) || ""
}))
});
I.setItem(B, JSON.stringify(V))
}
function h(W) {
var V = G("