Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

react-contribution-calendar

Package Overview
Dependencies
Maintainers
2
Versions
59
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

react-contribution-calendar - npm Package Compare versions

Comparing version 1.0.4 to 1.1.0

961

dist/index.js
import './styles/style.css';
import Ce from "react";
var Q = { exports: {} }, Y = {};
import Ie from "react";
var oe = { exports: {} }, B = {};
/**

@@ -13,21 +13,21 @@ * @license React

*/
var we;
function vr() {
if (we)
return Y;
we = 1;
var n = Ce, o = Symbol.for("react.element"), i = Symbol.for("react.fragment"), l = Object.prototype.hasOwnProperty, c = n.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner, p = { key: !0, ref: !0, __self: !0, __source: !0 };
function _(v, y, O) {
var g, S = {}, T = null, k = null;
O !== void 0 && (T = "" + O), y.key !== void 0 && (T = "" + y.key), y.ref !== void 0 && (k = y.ref);
for (g in y)
l.call(y, g) && !p.hasOwnProperty(g) && (S[g] = y[g]);
if (v && v.defaultProps)
for (g in y = v.defaultProps, y)
S[g] === void 0 && (S[g] = y[g]);
return { $$typeof: o, type: v, key: T, ref: k, props: S, _owner: c.current };
var Pe;
function hr() {
if (Pe)
return B;
Pe = 1;
var n = Ie, a = Symbol.for("react.element"), i = Symbol.for("react.fragment"), l = Object.prototype.hasOwnProperty, v = n.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner, p = { key: !0, ref: !0, __self: !0, __source: !0 };
function y(_, b, h) {
var c, d = {}, m = null, D = null;
h !== void 0 && (m = "" + h), b.key !== void 0 && (m = "" + b.key), b.ref !== void 0 && (D = b.ref);
for (c in b)
l.call(b, c) && !p.hasOwnProperty(c) && (d[c] = b[c]);
if (_ && _.defaultProps)
for (c in b = _.defaultProps, b)
d[c] === void 0 && (d[c] = b[c]);
return { $$typeof: a, type: _, key: m, ref: D, props: d, _owner: v.current };
}
return Y.Fragment = i, Y.jsx = _, Y.jsxs = _, Y;
return B.Fragment = i, B.jsx = y, B.jsxs = y, B;
}
var N = {};
var L = {};
/**

@@ -42,50 +42,50 @@ * @license React

*/
var je;
function pr() {
return je || (je = 1, process.env.NODE_ENV !== "production" && function() {
var n = Ce, o = Symbol.for("react.element"), i = Symbol.for("react.portal"), l = Symbol.for("react.fragment"), c = Symbol.for("react.strict_mode"), p = Symbol.for("react.profiler"), _ = Symbol.for("react.provider"), v = Symbol.for("react.context"), y = Symbol.for("react.forward_ref"), O = Symbol.for("react.suspense"), g = Symbol.for("react.suspense_list"), S = Symbol.for("react.memo"), T = Symbol.for("react.lazy"), k = Symbol.for("react.offscreen"), D = Symbol.iterator, ke = "@@iterator";
function Ae(e) {
var Ae;
function gr() {
return Ae || (Ae = 1, process.env.NODE_ENV !== "production" && function() {
var n = Ie, a = Symbol.for("react.element"), i = Symbol.for("react.portal"), l = Symbol.for("react.fragment"), v = Symbol.for("react.strict_mode"), p = Symbol.for("react.profiler"), y = Symbol.for("react.provider"), _ = Symbol.for("react.context"), b = Symbol.for("react.forward_ref"), h = Symbol.for("react.suspense"), c = Symbol.for("react.suspense_list"), d = Symbol.for("react.memo"), m = Symbol.for("react.lazy"), D = Symbol.for("react.offscreen"), J = Symbol.iterator, M = "@@iterator";
function j(e) {
if (e === null || typeof e != "object")
return null;
var r = D && e[D] || e[ke];
var r = J && e[J] || e[M];
return typeof r == "function" ? r : null;
}
var A = n.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED;
var O = n.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED;
function E(e) {
{
for (var r = arguments.length, t = new Array(r > 1 ? r - 1 : 0), a = 1; a < r; a++)
t[a - 1] = arguments[a];
Fe("error", e, t);
for (var r = arguments.length, t = new Array(r > 1 ? r - 1 : 0), o = 1; o < r; o++)
t[o - 1] = arguments[o];
V("error", e, t);
}
}
function Fe(e, r, t) {
function V(e, r, t) {
{
var a = A.ReactDebugCurrentFrame, f = a.getStackAddendum();
f !== "" && (r += "%s", t = t.concat([f]));
var d = t.map(function(u) {
return String(u);
var o = O.ReactDebugCurrentFrame, u = o.getStackAddendum();
u !== "" && (r += "%s", t = t.concat([u]));
var g = t.map(function(f) {
return String(f);
});
d.unshift("Warning: " + r), Function.prototype.apply.call(console[e], console, d);
g.unshift("Warning: " + r), Function.prototype.apply.call(console[e], console, g);
}
}
var Ie = !1, $e = !1, Me = !1, Ye = !1, Ne = !1, ne;
ne = Symbol.for("react.module.reference");
function We(e) {
return !!(typeof e == "string" || typeof e == "function" || e === l || e === p || Ne || e === c || e === O || e === g || Ye || e === k || Ie || $e || Me || typeof e == "object" && e !== null && (e.$$typeof === T || e.$$typeof === S || e.$$typeof === _ || e.$$typeof === v || e.$$typeof === y || // This needs to include all possible module reference object
var k = !1, We = !1, Be = !1, Le = !1, Je = !1, fe;
fe = Symbol.for("react.module.reference");
function Ve(e) {
return !!(typeof e == "string" || typeof e == "function" || e === l || e === p || Je || e === v || e === h || e === c || Le || e === D || k || We || Be || typeof e == "object" && e !== null && (e.$$typeof === m || e.$$typeof === d || e.$$typeof === y || e.$$typeof === _ || e.$$typeof === b || // This needs to include all possible module reference object
// types supported by any Flight configuration anywhere since
// we don't know which Flight build this will end up being used
// with.
e.$$typeof === ne || e.getModuleId !== void 0));
e.$$typeof === fe || e.getModuleId !== void 0));
}
function Le(e, r, t) {
var a = e.displayName;
if (a)
return a;
var f = r.displayName || r.name || "";
return f !== "" ? t + "(" + f + ")" : t;
function Ue(e, r, t) {
var o = e.displayName;
if (o)
return o;
var u = r.displayName || r.name || "";
return u !== "" ? t + "(" + u + ")" : t;
}
function ae(e) {
function ce(e) {
return e.displayName || "Context";
}
function w(e) {
function T(e) {
if (e == null)

@@ -104,7 +104,7 @@ return null;

return "Profiler";
case c:
case v:
return "StrictMode";
case O:
case h:
return "Suspense";
case g:
case c:
return "SuspenseList";

@@ -114,17 +114,17 @@ }

switch (e.$$typeof) {
case v:
case _:
var r = e;
return ae(r) + ".Consumer";
case _:
return ce(r) + ".Consumer";
case y:
var t = e;
return ae(t._context) + ".Provider";
case y:
return Le(e, e.render, "ForwardRef");
case S:
var a = e.displayName || null;
return a !== null ? a : w(e.type) || "Memo";
case T: {
var f = e, d = f._payload, u = f._init;
return ce(t._context) + ".Provider";
case b:
return Ue(e, e.render, "ForwardRef");
case d:
var o = e.displayName || null;
return o !== null ? o : T(e.type) || "Memo";
case m: {
var u = e, g = u._payload, f = u._init;
try {
return w(u(d));
return T(f(g));
} catch {

@@ -137,14 +137,14 @@ return null;

}
var P = Object.assign, $ = 0, le, oe, ie, se, ue, fe, ce;
function de() {
var P = Object.assign, N = 0, ue, ve, de, pe, ye, be, he;
function ge() {
}
de.__reactDisabledLog = !0;
function Je() {
ge.__reactDisabledLog = !0;
function qe() {
{
if ($ === 0) {
le = console.log, oe = console.info, ie = console.warn, se = console.error, ue = console.group, fe = console.groupCollapsed, ce = console.groupEnd;
if (N === 0) {
ue = console.log, ve = console.info, de = console.warn, pe = console.error, ye = console.group, be = console.groupCollapsed, he = console.groupEnd;
var e = {
configurable: !0,
enumerable: !0,
value: de,
value: ge,
writable: !0

@@ -162,8 +162,8 @@ };

}
$++;
N++;
}
}
function Ve() {
function Ge() {
{
if ($--, $ === 0) {
if (N--, N === 0) {
var e = {

@@ -176,66 +176,66 @@ configurable: !0,

log: P({}, e, {
value: le
value: ue
}),
info: P({}, e, {
value: oe
value: ve
}),
warn: P({}, e, {
value: ie
value: de
}),
error: P({}, e, {
value: se
value: pe
}),
group: P({}, e, {
value: ue
value: ye
}),
groupCollapsed: P({}, e, {
value: fe
value: be
}),
groupEnd: P({}, e, {
value: ce
value: he
})
});
}
$ < 0 && E("disabledDepth fell below zero. This is a bug in React. Please file an issue.");
N < 0 && E("disabledDepth fell below zero. This is a bug in React. Please file an issue.");
}
}
var B = A.ReactCurrentDispatcher, q;
function W(e, r, t) {
var Z = O.ReactCurrentDispatcher, Q;
function U(e, r, t) {
{
if (q === void 0)
if (Q === void 0)
try {
throw Error();
} catch (f) {
var a = f.stack.trim().match(/\n( *(at )?)/);
q = a && a[1] || "";
} catch (u) {
var o = u.stack.trim().match(/\n( *(at )?)/);
Q = o && o[1] || "";
}
return `
` + q + e;
` + Q + e;
}
}
var G = !1, L;
var ee = !1, q;
{
var Ue = typeof WeakMap == "function" ? WeakMap : Map;
L = new Ue();
var ze = typeof WeakMap == "function" ? WeakMap : Map;
q = new ze();
}
function ve(e, r) {
if (!e || G)
function me(e, r) {
if (!e || ee)
return "";
{
var t = L.get(e);
var t = q.get(e);
if (t !== void 0)
return t;
}
var a;
G = !0;
var f = Error.prepareStackTrace;
var o;
ee = !0;
var u = Error.prepareStackTrace;
Error.prepareStackTrace = void 0;
var d;
d = B.current, B.current = null, Je();
var g;
g = Z.current, Z.current = null, qe();
try {
if (r) {
var u = function() {
var f = function() {
throw Error();
};
if (Object.defineProperty(u.prototype, "props", {
if (Object.defineProperty(f.prototype, "props", {
set: function() {

@@ -246,14 +246,14 @@ throw Error();

try {
Reflect.construct(u, []);
} catch (j) {
a = j;
Reflect.construct(f, []);
} catch (C) {
o = C;
}
Reflect.construct(e, [], u);
Reflect.construct(e, [], f);
} else {
try {
u.call();
} catch (j) {
a = j;
f.call();
} catch (C) {
o = C;
}
e.call(u.prototype);
e.call(f.prototype);
}

@@ -263,23 +263,23 @@ } else {

throw Error();
} catch (j) {
a = j;
} catch (C) {
o = C;
}
e();
}
} catch (j) {
if (j && a && typeof j.stack == "string") {
for (var s = j.stack.split(`
`), R = a.stack.split(`
`), b = s.length - 1, h = R.length - 1; b >= 1 && h >= 0 && s[b] !== R[h]; )
h--;
for (; b >= 1 && h >= 0; b--, h--)
if (s[b] !== R[h]) {
if (b !== 1 || h !== 1)
} catch (C) {
if (C && o && typeof C.stack == "string") {
for (var s = C.stack.split(`
`), w = o.stack.split(`
`), R = s.length - 1, S = w.length - 1; R >= 1 && S >= 0 && s[R] !== w[S]; )
S--;
for (; R >= 1 && S >= 0; R--, S--)
if (s[R] !== w[S]) {
if (R !== 1 || S !== 1)
do
if (b--, h--, h < 0 || s[b] !== R[h]) {
if (R--, S--, S < 0 || s[R] !== w[S]) {
var x = `
` + s[b].replace(" at new ", " at ");
return e.displayName && x.includes("<anonymous>") && (x = x.replace("<anonymous>", e.displayName)), typeof e == "function" && L.set(e, x), x;
` + s[R].replace(" at new ", " at ");
return e.displayName && x.includes("<anonymous>") && (x = x.replace("<anonymous>", e.displayName)), typeof e == "function" && q.set(e, x), x;
}
while (b >= 1 && h >= 0);
while (R >= 1 && S >= 0);
break;

@@ -289,37 +289,37 @@ }

} finally {
G = !1, B.current = d, Ve(), Error.prepareStackTrace = f;
ee = !1, Z.current = g, Ge(), Error.prepareStackTrace = u;
}
var I = e ? e.displayName || e.name : "", Oe = I ? W(I) : "";
return typeof e == "function" && L.set(e, Oe), Oe;
var I = e ? e.displayName || e.name : "", ke = I ? U(I) : "";
return typeof e == "function" && q.set(e, ke), ke;
}
function Be(e, r, t) {
return ve(e, !1);
function He(e, r, t) {
return me(e, !1);
}
function qe(e) {
function Ke(e) {
var r = e.prototype;
return !!(r && r.isReactComponent);
}
function J(e, r, t) {
function G(e, r, t) {
if (e == null)
return "";
if (typeof e == "function")
return ve(e, qe(e));
return me(e, Ke(e));
if (typeof e == "string")
return W(e);
return U(e);
switch (e) {
case O:
return W("Suspense");
case g:
return W("SuspenseList");
case h:
return U("Suspense");
case c:
return U("SuspenseList");
}
if (typeof e == "object")
switch (e.$$typeof) {
case y:
return Be(e.render);
case S:
return J(e.type, r, t);
case T: {
var a = e, f = a._payload, d = a._init;
case b:
return He(e.render);
case d:
return G(e.type, r, t);
case m: {
var o = e, u = o._payload, g = o._init;
try {
return J(d(f), r, t);
return G(g(u), r, t);
} catch {

@@ -331,34 +331,34 @@ }

}
var V = Object.prototype.hasOwnProperty, pe = {}, be = A.ReactDebugCurrentFrame;
function U(e) {
var z = Object.prototype.hasOwnProperty, Ee = {}, _e = O.ReactDebugCurrentFrame;
function H(e) {
if (e) {
var r = e._owner, t = J(e.type, e._source, r ? r.type : null);
be.setExtraStackFrame(t);
var r = e._owner, t = G(e.type, e._source, r ? r.type : null);
_e.setExtraStackFrame(t);
} else
be.setExtraStackFrame(null);
_e.setExtraStackFrame(null);
}
function Ge(e, r, t, a, f) {
function Xe(e, r, t, o, u) {
{
var d = Function.call.bind(V);
for (var u in e)
if (d(e, u)) {
var g = Function.call.bind(z);
for (var f in e)
if (g(e, f)) {
var s = void 0;
try {
if (typeof e[u] != "function") {
var R = Error((a || "React class") + ": " + t + " type `" + u + "` is invalid; it must be a function, usually from the `prop-types` package, but received `" + typeof e[u] + "`.This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.");
throw R.name = "Invariant Violation", R;
if (typeof e[f] != "function") {
var w = Error((o || "React class") + ": " + t + " type `" + f + "` is invalid; it must be a function, usually from the `prop-types` package, but received `" + typeof e[f] + "`.This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.");
throw w.name = "Invariant Violation", w;
}
s = e[u](r, u, a, t, null, "SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED");
} catch (b) {
s = b;
s = e[f](r, f, o, t, null, "SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED");
} catch (R) {
s = R;
}
s && !(s instanceof Error) && (U(f), E("%s: type specification of %s `%s` is invalid; the type checker function must return `null` or an `Error` but returned a %s. You may have forgotten to pass an argument to the type checker creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and shape all require an argument).", a || "React class", t, u, typeof s), U(null)), s instanceof Error && !(s.message in pe) && (pe[s.message] = !0, U(f), E("Failed %s type: %s", t, s.message), U(null));
s && !(s instanceof Error) && (H(u), E("%s: type specification of %s `%s` is invalid; the type checker function must return `null` or an `Error` but returned a %s. You may have forgotten to pass an argument to the type checker creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and shape all require an argument).", o || "React class", t, f, typeof s), H(null)), s instanceof Error && !(s.message in Ee) && (Ee[s.message] = !0, H(u), E("Failed %s type: %s", t, s.message), H(null));
}
}
}
var ze = Array.isArray;
function z(e) {
return ze(e);
var Ze = Array.isArray;
function re(e) {
return Ze(e);
}
function He(e) {
function Qe(e) {
{

@@ -369,5 +369,5 @@ var r = typeof Symbol == "function" && Symbol.toStringTag, t = r && e[Symbol.toStringTag] || e.constructor.name || "Object";

}
function Ke(e) {
function er(e) {
try {
return ye(e), !1;
return Re(e), !1;
} catch {

@@ -377,10 +377,10 @@ return !0;

}
function ye(e) {
function Re(e) {
return "" + e;
}
function he(e) {
if (Ke(e))
return E("The provided key is an unsupported type %s. This value must be coerced to a string before before using it here.", He(e)), ye(e);
function Se(e) {
if (er(e))
return E("The provided key is an unsupported type %s. This value must be coerced to a string before before using it here.", Qe(e)), Re(e);
}
var M = A.ReactCurrentOwner, Xe = {
var W = O.ReactCurrentOwner, rr = {
key: !0,

@@ -390,6 +390,6 @@ ref: !0,

__source: !0
}, ge, me, H;
H = {};
function Ze(e) {
if (V.call(e, "ref")) {
}, Fe, we, te;
te = {};
function tr(e) {
if (z.call(e, "ref")) {
var r = Object.getOwnPropertyDescriptor(e, "ref").get;

@@ -401,4 +401,4 @@ if (r && r.isReactWarning)

}
function Qe(e) {
if (V.call(e, "key")) {
function nr(e) {
if (z.call(e, "key")) {
var r = Object.getOwnPropertyDescriptor(e, "key").get;

@@ -410,12 +410,12 @@ if (r && r.isReactWarning)

}
function er(e, r) {
if (typeof e.ref == "string" && M.current && r && M.current.stateNode !== r) {
var t = w(M.current.type);
H[t] || (E('Component "%s" contains the string ref "%s". Support for string refs will be removed in a future major release. This case cannot be automatically converted to an arrow function. We ask you to manually fix this case by using useRef() or createRef() instead. Learn more about using refs safely here: https://reactjs.org/link/strict-mode-string-ref', w(M.current.type), e.ref), H[t] = !0);
function ar(e, r) {
if (typeof e.ref == "string" && W.current && r && W.current.stateNode !== r) {
var t = T(W.current.type);
te[t] || (E('Component "%s" contains the string ref "%s". Support for string refs will be removed in a future major release. This case cannot be automatically converted to an arrow function. We ask you to manually fix this case by using useRef() or createRef() instead. Learn more about using refs safely here: https://reactjs.org/link/strict-mode-string-ref', T(W.current.type), e.ref), te[t] = !0);
}
}
function rr(e, r) {
function lr(e, r) {
{
var t = function() {
ge || (ge = !0, E("%s: `key` is not a prop. Trying to access it will result in `undefined` being returned. If you need to access the same value within the child component, you should pass it as a different prop. (https://reactjs.org/link/special-props)", r));
Fe || (Fe = !0, E("%s: `key` is not a prop. Trying to access it will result in `undefined` being returned. If you need to access the same value within the child component, you should pass it as a different prop. (https://reactjs.org/link/special-props)", r));
};

@@ -428,6 +428,6 @@ t.isReactWarning = !0, Object.defineProperty(e, "key", {

}
function tr(e, r) {
function or(e, r) {
{
var t = function() {
me || (me = !0, E("%s: `ref` is not a prop. Trying to access it will result in `undefined` being returned. If you need to access the same value within the child component, you should pass it as a different prop. (https://reactjs.org/link/special-props)", r));
we || (we = !0, E("%s: `ref` is not a prop. Trying to access it will result in `undefined` being returned. If you need to access the same value within the child component, you should pass it as a different prop. (https://reactjs.org/link/special-props)", r));
};

@@ -440,6 +440,6 @@ t.isReactWarning = !0, Object.defineProperty(e, "ref", {

}
var nr = function(e, r, t, a, f, d, u) {
var ir = function(e, r, t, o, u, g, f) {
var s = {
// This tag allows us to uniquely identify this as a React Element
$$typeof: o,
$$typeof: a,
// Built-in properties that belong on the element

@@ -449,5 +449,5 @@ type: e,

ref: t,
props: u,
props: f,
// Record the component responsible for creating this element.
_owner: d
_owner: g
};

@@ -463,3 +463,3 @@ return s._store = {}, Object.defineProperty(s._store, "validated", {

writable: !1,
value: a
value: o
}), Object.defineProperty(s, "_source", {

@@ -469,40 +469,40 @@ configurable: !1,

writable: !1,
value: f
value: u
}), Object.freeze && (Object.freeze(s.props), Object.freeze(s)), s;
};
function ar(e, r, t, a, f) {
function sr(e, r, t, o, u) {
{
var d, u = {}, s = null, R = null;
t !== void 0 && (he(t), s = "" + t), Qe(r) && (he(r.key), s = "" + r.key), Ze(r) && (R = r.ref, er(r, f));
for (d in r)
V.call(r, d) && !Xe.hasOwnProperty(d) && (u[d] = r[d]);
var g, f = {}, s = null, w = null;
t !== void 0 && (Se(t), s = "" + t), nr(r) && (Se(r.key), s = "" + r.key), tr(r) && (w = r.ref, ar(r, u));
for (g in r)
z.call(r, g) && !rr.hasOwnProperty(g) && (f[g] = r[g]);
if (e && e.defaultProps) {
var b = e.defaultProps;
for (d in b)
u[d] === void 0 && (u[d] = b[d]);
var R = e.defaultProps;
for (g in R)
f[g] === void 0 && (f[g] = R[g]);
}
if (s || R) {
var h = typeof e == "function" ? e.displayName || e.name || "Unknown" : e;
s && rr(u, h), R && tr(u, h);
if (s || w) {
var S = typeof e == "function" ? e.displayName || e.name || "Unknown" : e;
s && lr(f, S), w && or(f, S);
}
return nr(e, s, R, f, a, M.current, u);
return ir(e, s, w, u, o, W.current, f);
}
}
var K = A.ReactCurrentOwner, _e = A.ReactDebugCurrentFrame;
function F(e) {
var ne = O.ReactCurrentOwner, xe = O.ReactDebugCurrentFrame;
function $(e) {
if (e) {
var r = e._owner, t = J(e.type, e._source, r ? r.type : null);
_e.setExtraStackFrame(t);
var r = e._owner, t = G(e.type, e._source, r ? r.type : null);
xe.setExtraStackFrame(t);
} else
_e.setExtraStackFrame(null);
xe.setExtraStackFrame(null);
}
var X;
X = !1;
function Z(e) {
return typeof e == "object" && e !== null && e.$$typeof === o;
var ae;
ae = !1;
function le(e) {
return typeof e == "object" && e !== null && e.$$typeof === a;
}
function Ee() {
function De() {
{
if (K.current) {
var e = w(K.current.type);
if (ne.current) {
var e = T(ne.current.type);
if (e)

@@ -516,3 +516,3 @@ return `

}
function lr(e) {
function fr(e) {
{

@@ -528,6 +528,6 @@ if (e !== void 0) {

}
var Re = {};
function or(e) {
var Te = {};
function cr(e) {
{
var r = Ee();
var r = De();
if (!r) {

@@ -542,3 +542,3 @@ var t = typeof e == "string" ? e : e.displayName || e.name;

}
function Se(e, r) {
function Ce(e, r) {
{

@@ -548,30 +548,30 @@ if (!e._store || e._store.validated || e.key != null)

e._store.validated = !0;
var t = or(r);
if (Re[t])
var t = cr(r);
if (Te[t])
return;
Re[t] = !0;
var a = "";
e && e._owner && e._owner !== K.current && (a = " It was passed a child from " + w(e._owner.type) + "."), F(e), E('Each child in a list should have a unique "key" prop.%s%s See https://reactjs.org/link/warning-keys for more information.', t, a), F(null);
Te[t] = !0;
var o = "";
e && e._owner && e._owner !== ne.current && (o = " It was passed a child from " + T(e._owner.type) + "."), $(e), E('Each child in a list should have a unique "key" prop.%s%s See https://reactjs.org/link/warning-keys for more information.', t, o), $(null);
}
}
function Te(e, r) {
function Oe(e, r) {
{
if (typeof e != "object")
return;
if (z(e))
if (re(e))
for (var t = 0; t < e.length; t++) {
var a = e[t];
Z(a) && Se(a, r);
var o = e[t];
le(o) && Ce(o, r);
}
else if (Z(e))
else if (le(e))
e._store && (e._store.validated = !0);
else if (e) {
var f = Ae(e);
if (typeof f == "function" && f !== e.entries)
for (var d = f.call(e), u; !(u = d.next()).done; )
Z(u.value) && Se(u.value, r);
var u = j(e);
if (typeof u == "function" && u !== e.entries)
for (var g = u.call(e), f; !(f = g.next()).done; )
le(f.value) && Ce(f.value, r);
}
}
}
function ir(e) {
function ur(e) {
{

@@ -584,5 +584,5 @@ var r = e.type;

t = r.propTypes;
else if (typeof r == "object" && (r.$$typeof === y || // Note: Memo only checks outer props here.
else if (typeof r == "object" && (r.$$typeof === b || // Note: Memo only checks outer props here.
// Inner props are checked in the reconciler.
r.$$typeof === S))
r.$$typeof === d))
t = r.propTypes;

@@ -592,8 +592,8 @@ else

if (t) {
var a = w(r);
Ge(t, e.props, "prop", a, e);
} else if (r.PropTypes !== void 0 && !X) {
X = !0;
var f = w(r);
E("Component %s declared `PropTypes` instead of `propTypes`. Did you misspell the property assignment?", f || "Unknown");
var o = T(r);
Xe(t, e.props, "prop", o, e);
} else if (r.PropTypes !== void 0 && !ae) {
ae = !0;
var u = T(r);
E("Component %s declared `PropTypes` instead of `propTypes`. Did you misspell the property assignment?", u || "Unknown");
}

@@ -603,35 +603,35 @@ typeof r.getDefaultProps == "function" && !r.getDefaultProps.isReactClassApproved && E("getDefaultProps is only used on classic React.createClass definitions. Use a static property named `defaultProps` instead.");

}
function sr(e) {
function vr(e) {
{
for (var r = Object.keys(e.props), t = 0; t < r.length; t++) {
var a = r[t];
if (a !== "children" && a !== "key") {
F(e), E("Invalid prop `%s` supplied to `React.Fragment`. React.Fragment can only have `key` and `children` props.", a), F(null);
var o = r[t];
if (o !== "children" && o !== "key") {
$(e), E("Invalid prop `%s` supplied to `React.Fragment`. React.Fragment can only have `key` and `children` props.", o), $(null);
break;
}
}
e.ref !== null && (F(e), E("Invalid attribute `ref` supplied to `React.Fragment`."), F(null));
e.ref !== null && ($(e), E("Invalid attribute `ref` supplied to `React.Fragment`."), $(null));
}
}
function xe(e, r, t, a, f, d) {
function je(e, r, t, o, u, g) {
{
var u = We(e);
if (!u) {
var f = Ve(e);
if (!f) {
var s = "";
(e === void 0 || typeof e == "object" && e !== null && Object.keys(e).length === 0) && (s += " You likely forgot to export your component from the file it's defined in, or you might have mixed up default and named imports.");
var R = lr(f);
R ? s += R : s += Ee();
var b;
e === null ? b = "null" : z(e) ? b = "array" : e !== void 0 && e.$$typeof === o ? (b = "<" + (w(e.type) || "Unknown") + " />", s = " Did you accidentally export a JSX literal instead of a component?") : b = typeof e, E("React.jsx: type is invalid -- expected a string (for built-in components) or a class/function (for composite components) but got: %s.%s", b, s);
var w = fr(u);
w ? s += w : s += De();
var R;
e === null ? R = "null" : re(e) ? R = "array" : e !== void 0 && e.$$typeof === a ? (R = "<" + (T(e.type) || "Unknown") + " />", s = " Did you accidentally export a JSX literal instead of a component?") : R = typeof e, E("React.jsx: type is invalid -- expected a string (for built-in components) or a class/function (for composite components) but got: %s.%s", R, s);
}
var h = ar(e, r, t, f, d);
if (h == null)
return h;
if (u) {
var S = sr(e, r, t, u, g);
if (S == null)
return S;
if (f) {
var x = r.children;
if (x !== void 0)
if (a)
if (z(x)) {
if (o)
if (re(x)) {
for (var I = 0; I < x.length; I++)
Te(x[I], e);
Oe(x[I], e);
Object.freeze && Object.freeze(x);

@@ -641,26 +641,34 @@ } else

else
Te(x, e);
Oe(x, e);
}
return e === l ? sr(h) : ir(h), h;
return e === l ? vr(S) : ur(S), S;
}
}
function ur(e, r, t) {
return xe(e, r, t, !0);
function dr(e, r, t) {
return je(e, r, t, !0);
}
function fr(e, r, t) {
return xe(e, r, t, !1);
function pr(e, r, t) {
return je(e, r, t, !1);
}
var cr = fr, dr = ur;
N.Fragment = l, N.jsx = cr, N.jsxs = dr;
}()), N;
var yr = pr, br = dr;
L.Fragment = l, L.jsx = yr, L.jsxs = br;
}()), L;
}
process.env.NODE_ENV === "production" ? Q.exports = vr() : Q.exports = pr();
var m = Q.exports;
function ee({ children: n, textColor: o, style: i, colSpan: l, ...c }) {
return /* @__PURE__ */ m.jsxs("td", { className: "calendar-label", style: i, colSpan: l, ...c, children: [
/* @__PURE__ */ m.jsx("span", { className: "sr-only", children: n }),
/* @__PURE__ */ m.jsx("span", { className: "calendar-label-text", "aria-hidden": "true", style: { color: o }, children: n })
process.env.NODE_ENV === "production" ? oe.exports = hr() : oe.exports = gr();
var F = oe.exports;
function ie({ children: n, textColor: a, style: i, colSpan: l, ...v }) {
return /* @__PURE__ */ F.jsxs("td", { className: "calendar-label", style: i, colSpan: l, ...v, children: [
/* @__PURE__ */ F.jsx("span", { className: "sr-only", children: n }),
/* @__PURE__ */ F.jsx("span", { className: "calendar-label-text", "aria-hidden": "true", style: { color: a }, children: n })
] });
}
const br = {
const mr = {
//light themes
empty: {
level0: "#ffffff",
level1: "#ffffff",
level2: "#ffffff",
level3: "#ffffff",
level4: "#ffffff"
},
grass: {

@@ -694,2 +702,9 @@ level0: "#ebedf0",

},
ocean: {
level0: "#ccf6ff",
level1: "#80d0ff",
level2: "#00d1ff",
level3: "#00ffff",
level4: "#0040ff"
},
sky: {

@@ -723,12 +738,5 @@ level0: "#ffffff",

},
blue_pop: {
level0: "#ff008c",
level1: "#ff00e4",
level2: "#d400ff",
level3: "#9800ff",
level4: "#057dff"
},
mustard: {
level0: "#f5b40d",
level1: "#f7c33d",
level0: "#cc7b00",
level1: "#f5b40d",
level2: "#f9d26e",

@@ -738,10 +746,66 @@ level3: "#fbe19e",

},
//dark themes
dark_vomit: {
level0: "#660099",
level1: "#663399",
gray: {
level0: "#FFFFFF",
level1: "#D4D4D4",
level2: "#B4B4B4",
level3: "#909090",
level4: "#494848"
},
vomit: {
level0: "#badbdb",
level1: "#669999",
level2: "#666699",
level3: "#669999",
level4: "#66cc99"
level3: "#663399",
level4: "#660099"
},
neonpunk: {
level0: "#FFFFFF",
level1: "#B6FFFE",
level2: "#48FDFE",
level3: "#F20BF8",
level4: "#EE018F"
},
citypop: {
level0: "#c2b3ff",
level1: "#5B33FE",
level2: "#b84dff",
level3: "#d52dff",
level4: "#FA43F9"
},
coral: {
level0: "#fef3e7",
level1: "#f7b267",
level2: "#f79d65",
level3: "#f4845f",
level4: "#f25c54"
},
//dark themes
dark_empty: {
level0: "#000000",
level1: "#000000",
level2: "#000000",
level3: "#000000",
level4: "#000000"
},
dark_grass: {
level0: "#161b22",
level1: "#0e4429",
level2: "#006d32",
level3: "#26a641",
level4: "#39d353"
},
dark_cherry: {
level0: "#1b1819",
level2: "#250e16",
level3: "#2e0513",
level1: "#5d0926",
level4: "#a21043"
},
dark_cherry_blossom: {
level0: "#1b1819",
level1: "#5d0926",
level2: "#a22a52",
level3: "#c80064",
level4: "#ffb094"
},
dark_pink: {

@@ -754,12 +818,5 @@ level0: "#000000",

},
dark_blue: {
level0: "#330033",
level1: "#330066",
level2: "#330099",
level3: "#3300cc",
level4: "#3300ff"
},
dark_ocean: {
level0: "#0000b3",
level1: "#0010d9",
level0: "#00004d",
level1: "#0000b3",
level2: "#0040ff",

@@ -769,8 +826,8 @@ level3: "#00bfff",

},
dark_grass: {
level0: "#161b22",
level1: "#0e4429",
level2: "#006d32",
level3: "#26a641",
level4: "#39d353"
dark_sky: {
level0: "#303636",
level1: "#616b6b",
level2: "#99a3a3",
level3: "#86b6b6",
level4: "#54bebe"
},

@@ -790,5 +847,54 @@ dark_halloween: {

level4: "#b6e3ff"
},
dark_purquoise: {
level0: "#303636",
level1: "#7c8288",
level2: "#8d9caa",
level3: "#7c9bb9",
level4: "#5b82a8"
},
dark_mustard: {
level0: "#2a2722",
level1: "#4d2e00",
level2: "#cc7b00",
level3: "#dca009",
level4: "#ffc905"
},
dark_gray: {
level0: "#333333",
level1: "#555555",
level2: "#777777",
level3: "#999999",
level4: "#D4D4D4"
},
dark_vomit: {
level0: "#261339",
level1: "#663399",
level2: "#666699",
level3: "#669999",
level4: "#66cc99"
},
dark_neonpunk: {
level0: "#3E1340",
level1: "#EE018F",
level2: "#FF00FE",
level3: "#41FEFF",
level4: "#BFFFFC"
},
dark_citypop: {
level0: "#514c67",
level1: "#5B33FE",
level2: "#B74FFB",
level3: "#D52DE5",
level4: "#FA43F9"
},
dark_coral: {
level0: "#504949",
level2: "#df6d68",
level3: "#f25c54",
level1: "#f79d65",
level4: "#f7b267"
}
}, yr = (n = /* @__PURE__ */ new Date()) => {
const o = {
}, kr = (n = /* @__PURE__ */ new Date()) => {
const a = {
Sun: "Sunday",

@@ -815,113 +921,174 @@ Mon: "Monday",

}, l = n.toString().split(" ");
return { year: l[3], month: i[l[1]], day: parseInt(l[2], 10), date: o[l[0]] };
}, hr = (n, o, i) => {
const l = Pe(o, i, n), c = yr(new Date(n, l, i));
return `${c.date}, ${c.month} ${c.day}, ${c.year}`;
}, gr = (n, o, i) => {
const l = Pe(o, i, n);
return `${n}-${String(l + 1).padStart(2, "0")}-${String(i).padStart(2, "0")}`;
}, mr = (n = C()) => n % 4 === 0 && n % 100 !== 0 || n % 400 === 0, re = (n = C()) => [31, mr(n) ? 29 : 28, 31, 30, 31, 30, 31, 31, 30, 31, 30, 31], De = (n = C()) => new Date(n, 0, 1).getDay(), C = () => (/* @__PURE__ */ new Date()).getFullYear(), _r = (n) => n.reduce((o, i) => o + i, 0), te = (n = C()) => {
const o = re(n), i = De(n), l = [];
let c = i;
for (let p = 0; p < 12; p++) {
const _ = o[p];
let v = 0;
for (let y = 0; y < _; y++)
c === 0 && v++, c = (c + 1) % 7;
p === 0 && i !== 0 && v++, l.push(v);
return {
year: l[3],
month: i[l[1]],
day: parseInt(l[2], 10),
date: a[l[0]]
};
}, Me = (n, a, i) => `${n}-${String(a + 1).padStart(2, "0")}-${String(i).padStart(2, "0")}`, Er = (n, a, i) => `${n}-${String(a).padStart(2, "0")}-${String(i).padStart(2, "0")}`, A = (n) => +n.slice(0, 4), $e = (n) => +n.slice(5, 7), Pr = (n) => +n.slice(8, 10), _r = (n = Y()) => n % 4 === 0 && n % 100 !== 0 || n % 400 === 0, se = (n = Y()) => [31, _r(n) ? 29 : 28, 31, 30, 31, 30, 31, 31, 30, 31, 30, 31], X = (n = Y()) => new Date(n, 0, 1).getDay(), Ar = (n) => new Date(n).getDay(), Y = () => (/* @__PURE__ */ new Date()).getFullYear(), Mr = (n = Y(), a, i) => {
const l = se(n), v = X(n), p = [];
let y = v;
for (let _ = 0; _ < 12; _++) {
const b = l[_];
let h = 0;
for (let c = 0; c < b; c++)
y === 0 && h++, y = (y + 1) % 7;
_ === 0 && v !== 0 && h++, p.push(h);
}
return l;
}, Pe = (n, o, i = C()) => {
const l = te(i), c = re(i);
let p = 0, _ = 0, v = 0;
for (v = 0; v < l.length; v++) {
if (p += l[v], _ += c[v], n + 1 === p && o < 7)
return v + 1;
if (n < p && o <= _)
return v;
return n !== a && v !== 0 && a !== i && (p[0] -= 1), p;
}, Rr = (n) => {
const a = /* @__PURE__ */ new Map();
return n.forEach((i) => {
Object.keys(i).forEach((l) => {
a.set(l, i[l]);
});
}), a;
}, Sr = (n) => typeof n == "string" ? mr[n] : n, Fr = (n, a) => {
let i = 0;
for (let l = n; l <= a; ++l)
i += Ye(n, l === n);
return new Array(7).fill(0).map(() => new Array(i).fill(0));
}, wr = (n, a) => {
let i = 0;
for (let l = n; l <= a; ++l)
i += Ye(n, l === n);
return new Array(7).fill("").map(() => new Array(i).fill(""));
}, Ye = (n, a) => {
const i = X(n);
return a || i === 0 ? 53 : 52;
}, xr = (n, a) => {
const i = A(n), l = A(a), v = Fr(i, l);
let p = 0, y = 1;
for (let _ = i; _ <= l; ++_) {
const b = X(_), h = se(_);
let c = 0, d = 1, m = b;
for (; c < 12; ) {
for (let D = 0; D < h[c]; ++D)
v[m % 7][~~(m / 7) + p] = y, m++, d++, y++;
d > h[c] && (d = 1, c++);
}
p += ~~(m / 7);
}
return v;
}, Er = (n) => new Array(7).fill(0).map(() => new Array(n).fill(0)), Rr = (n, o = C()) => {
const i = re(o), l = De(o);
let c = 0, p = 1, _ = l;
for (; c < 12; ) {
for (let v = 0; v < i[c]; v++)
n[_ % 7][~~(_ / 7)] = p, _++, p++;
p > i[c] && (p = 1, c++);
}, Ne = (n, a) => {
const i = A(n), l = A(a), v = wr(i, l);
let p = 0;
for (let y = i; y <= l; ++y) {
const _ = X(y), b = se(y);
let h = 0, c = 1, d = _;
for (; h < 12; ) {
for (let m = 0; m < b[h]; ++m) {
const D = Er(y, h + 1, c);
v[d % 7][~~(d / 7) + p] = D, d++, c++;
}
c > b[h] && (c = 1, h++);
}
p += ~~(d / 7);
}
return n;
}, Sr = (n = C()) => {
const o = te(n), i = _r(o), l = Er(i);
return Rr(l, n);
}, Tr = (n) => {
const o = /* @__PURE__ */ new Map();
return n.forEach((i) => {
Object.keys(i).forEach((l) => {
o.set(l, i[l]);
});
}), o;
}, xr = (n) => typeof n == "string" ? br[n] : n;
function Or({ textColor: n }) {
const o = C(), i = ["Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sep", "Oct", "Nov", "Dec"], l = te(o);
return /* @__PURE__ */ m.jsx("thead", { children: /* @__PURE__ */ m.jsxs("tr", { children: [
/* @__PURE__ */ m.jsx(ee, { textColor: n, style: { width: "40px" }, colSpan: 1, children: " " }),
i.map((c, p) => /* @__PURE__ */ m.jsx(ee, { textColor: n, colSpan: l[p], children: c }, c))
return v;
}, K = (n, a) => {
const i = `${n}-01-01`, l = Dr(i, a), v = xr(i, a);
for (let p = 0; p < v.length; ++p)
for (let y = 0; y < v[p].length; ++y)
if (l === v[p][y])
return { row: p, col: y };
return { row: 0, col: 0 };
}, Dr = (n, a) => {
const i = new Date(n);
return (new Date(a).getTime() - i.getTime()) / (1e3 * 60 * 60 * 24) + 1;
};
function Tr({ start: n, end: a, textColor: i }) {
const l = Ne(n, a), { row: v, col: p } = K(A(n), n), { col: y } = K(A(n), a), _ = ["Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sep", "Oct", "Nov", "Dec"], b = [], h = [];
let c = -1;
for (let d = p; d <= y; ++d) {
let m = 0;
d === p ? m = $e(l[v][d]) - 1 : m = $e(l[0][d]) - 1, m !== c && (b.push(_[m]), c = m, h.push(0)), h[h.length - 1]++;
}
return /* @__PURE__ */ F.jsx("thead", { children: /* @__PURE__ */ F.jsxs("tr", { children: [
/* @__PURE__ */ F.jsx(ie, { textColor: i, style: { width: "40px" }, colSpan: 1, children: " " }),
b.map((d, m) => /* @__PURE__ */ F.jsx(ie, { textColor: i, colSpan: h[m], children: d }, m))
] }) });
}
function wr({ children: n, style: o, dataTooltip: i, dataLevel: l, themeProps: c, ...p }) {
return /* @__PURE__ */ m.jsx(
function Cr({ children: n, style: a, dataTooltip: i, dataLevel: l, themeProps: v, ...p }) {
return /* @__PURE__ */ F.jsx(
"td",
{
className: "calendar-cell top half-arrow",
style: { ...o, backgroundColor: c[`level${l}`] },
style: { ...a, backgroundColor: v[`level${l}`] },
"data-tooltip": i,
"data-level": l,
...p,
children: /* @__PURE__ */ m.jsx("span", { className: "sr-only", children: n })
children: /* @__PURE__ */ F.jsx("span", { className: "sr-only", children: n })
}
);
}
function jr({ data: n, textColor: o, theme: i }) {
const l = C(), c = ["Sun", "Mon", "Tue", "Wed", "Thu", "Fri", "Sat"], p = Sr(l), v = ((O) => {
const g = xr(O);
return g || console.error("Invalid theme name"), g;
})(i), y = Tr(n);
return /* @__PURE__ */ m.jsx("tbody", { children: c.map((O, g) => /* @__PURE__ */ m.jsxs("tr", { children: [
/* @__PURE__ */ m.jsx(ee, { tabIndex: 0, textColor: o, style: { textAlign: "inherit" }, children: O }),
p[g].map((S, T) => {
const k = gr(l, T, S), D = y.get(k);
return S ? /* @__PURE__ */ m.jsx(
wr,
function Or({ data: n, start: a, end: i, textColor: l, theme: v }) {
const p = A(a), { row: y, col: _ } = K(p, a), { row: b, col: h } = K(p, i), c = ["Sun", "Mon", "Tue", "Wed", "Thu", "Fri", "Sat"], d = Ne(a, i), D = ((M) => Sr(M))(v), J = Rr(n);
return /* @__PURE__ */ F.jsx("tbody", { children: c.map((M, j) => /* @__PURE__ */ F.jsxs("tr", { children: [
/* @__PURE__ */ F.jsx(ie, { tabIndex: 0, textColor: l, style: { textAlign: "inherit" }, children: M }),
d[j].map((O, E) => {
if (!O)
return /* @__PURE__ */ F.jsx("td", { style: { padding: "0", display: "none" } }, E);
if (E < _ || E > h)
return /* @__PURE__ */ F.jsx("td", { style: { padding: "0", display: "none" } }, E);
if (E === _ && j < y || E === h && j > b)
return /* @__PURE__ */ F.jsx(
"td",
{
style: {
padding: 0,
outline: "1px solid rgba(27, 31, 35, 0.06)",
borderRadius: "2px",
outlineOffset: "-1px",
shapeRendering: "geometricPrecision"
}
},
E
);
const V = d[j][E], k = J.get(V);
return /* @__PURE__ */ F.jsx(
Cr,
{
tabIndex: -1,
style: { width: "10px", height: "10px" },
dataLevel: D !== void 0 ? D.level : 0,
"data-content": JSON.stringify(D == null ? void 0 : D.data),
dataTooltip: hr(l, T, S),
themeProps: v
dataLevel: k !== void 0 ? k.level : 0,
"data-content": JSON.stringify(k == null ? void 0 : k.data),
dataTooltip: V,
themeProps: D
},
T
) : /* @__PURE__ */ m.jsx("td", {}, T);
E
);
})
] }, O)) });
] }, M)) });
}
function Dr({ data: n = [], textColor: o = "#000", theme: i = "grass" }) {
return /* @__PURE__ */ m.jsx("div", { className: "container", children: /* @__PURE__ */ m.jsxs("table", { children: [
/* @__PURE__ */ m.jsx(Or, { textColor: o }),
/* @__PURE__ */ m.jsx(jr, { data: n, textColor: o, theme: i })
function $r({
data: n = [],
textColor: a = "#fff",
theme: i = "grass",
start: l = Me(Y(), 0, 1),
end: v = Me(Y(), 11, 31)
}) {
return /* @__PURE__ */ F.jsx("div", { className: "container", children: /* @__PURE__ */ F.jsxs("table", { children: [
/* @__PURE__ */ F.jsx(Tr, { textColor: a, start: l, end: v }),
/* @__PURE__ */ F.jsx(Or, { data: n, textColor: a, theme: i, start: l, end: v })
] }) });
}
export {
Dr as ContributionCalendar,
xr as createTheme,
_r as getArraySum,
te as getColumnSpans,
C as getCurrentYear,
yr as getDateDetails,
gr as getDateString,
hr as getDateTooltip,
Sr as getDayArrayFromYear,
Pe as getMonthIndex,
mr as isLeapYear,
Tr as parseInputData
$r as ContributionCalendar,
Sr as createTheme,
Ne as fillDayArray,
xr as fillIndexArray,
Mr as getColumnSpansForYears,
Y as getCurrentYear,
kr as getDateDetails,
Me as getDateString,
Ar as getDayIndexOfMonth,
Dr as getDaysBetween,
X as getFirstDayIndexOfYear,
K as getRowAndColumnIndexFromDate,
_r as isLeapYear,
Pr as parseDayFromDateString,
Rr as parseInputData,
$e as parseMonthFromDateString,
A as parseYearFromDateString
};

@@ -1,2 +0,2 @@

// Type definitions for react-contribution-calendar 1.0.3
// Type definitions for react-contribution-calendar 1.1.0
// Project: https://github.com/seiwon-yaehee/react-contribution-calendar

@@ -26,4 +26,12 @@ // Definitions by: Seiwon Park <https://github.com/SeiwonPark>

/**
* The text color of calendar indexes for months and dates.
* Start date of calendar, defaults to 1st January of current year.
*/
start?: string
/**
* End date of calendar, defaults to 31st December of current year.
*/
end?: string
/**
* The text color of calendar indexes for months and dates, defaults to `#000`.
*/
textColor?: string

@@ -30,0 +38,0 @@ /**

{
"name": "react-contribution-calendar",
"description": "A GitHub-like contribution calendar component for React",
"version": "1.0.4",
"version": "1.1.0",
"type": "module",

@@ -45,10 +45,10 @@ "main": "./dist/index.js",

"devDependencies": {
"@types/node": "^20.4.7",
"@types/react": "^18.2.15",
"@types/node": "^20.5.0",
"@types/react": "^18.2.20",
"@types/react-dom": "^18.2.7",
"@typescript-eslint/eslint-plugin": "^6.0.0",
"@typescript-eslint/parser": "^6.0.0",
"@vitejs/plugin-react": "^4.0.3",
"@typescript-eslint/eslint-plugin": "^6.4.0",
"@typescript-eslint/parser": "^6.4.0",
"@vitejs/plugin-react": "^4.0.4",
"@vitejs/plugin-react-swc": "^3.3.2",
"eslint": "^8.45.0",
"eslint": "^8.47.0",
"eslint-plugin-prettier": "^4.2.1",

@@ -61,5 +61,5 @@ "eslint-plugin-react": "^7.33.1",

"react-dom": "^18.2.0",
"typescript": "^5.0.2",
"vite": "^4.4.5",
"vite-plugin-dts": "^3.5.0",
"typescript": "^5.1.6",
"vite": "^4.4.9",
"vite-plugin-dts": "^3.5.2",
"vite-plugin-libcss": "^1.1.1",

@@ -66,0 +66,0 @@ "vite-tsconfig-paths": "^4.2.0"

@@ -24,2 +24,7 @@ # react-contribution-calendar

{
'2020-04-20': {
level: 2,
}
},
{
'2023-07-08': {

@@ -36,3 +41,3 @@ level: 1,

{
'2023-12-31': {
'2023-03-31': {
level: 3,

@@ -46,3 +51,9 @@ data: {

<ContributionCalendar data={data} />
<ContributionCalendar
data={data}
start="2020-04-04"
end="2023-05-19"
textColor="#000000"
theme="grass"
/>
```

@@ -76,2 +87,5 @@

```
- `start`: Optional. The starting date for the calendar to start, defaults to current year's January 1st(`YYYY-MM-DD` format).
- `end`: Optional. The ending date for the calendar to end, defaults to current year's December 31st(`YYYY-MM-DD` format).
- `textColor`: Optional. The color of indexes. String color code format.
- `theme`: Optional. A string that represents a predefined theme name, or an object with custom theme colors. Defaults to `grass`.

@@ -98,2 +112,11 @@

#### `pink`
<img src="./images/pink.png" alt="pink" with=600 />
#### `halloween`
<img src="./images/halloween.png" alt="halloween" with=600 />
#### `winter`
<img src="./images/winter.png" alt="winter" with=600 />
#### `cherry`

@@ -105,14 +128,5 @@ <img src="./images/cherry.png" alt="cherry" with=600 />

#### `pink`
<img src="./images/pink.png" alt="pink" with=600 />
#### `sky`
<img src="./images/sky.png" alt="sky" with=600 />
#### `halloween`
<img src="./images/halloween.png" alt="halloween" with=600 />
#### `winter`
<img src="./images/winter.png" alt="winter" with=600 />
#### `purquoise`

@@ -130,4 +144,4 @@ <img src="./images/purquoise.png" alt="purquoise" with=600 />

### Dark Themes
#### `dark_vomit`
<img src="./images/dark_vomit.png" alt="dark_vomit" with=600 />
#### `dark_grass`
<img src="./images/dark_grass.png" alt="dark_grass" with=600 />

@@ -137,2 +151,8 @@ #### `dark_pink`

#### `dark_halloween`
<img src="./images/dark_halloween.png" alt="dark_halloween" with=600 />
#### `dark_winter`
<img src="./images/dark_winter.png" alt="dark_winter" with=600 />
#### `dark_blue`

@@ -144,11 +164,5 @@ <img src="./images/dark_blue.png" alt="dark_blue" with=600 />

#### `dark_grass`
<img src="./images/dark_grass.png" alt="dark_grass" with=600 />
#### `dark_vomit`
<img src="./images/dark_vomit.png" alt="dark_vomit" with=600 />
#### `dark_halloween`
<img src="./images/dark_halloween.png" alt="dark_halloween" with=600 />
#### `dark_winter`
<img src="./images/dark_winter.png" alt="dark_winter" with=600 />
<br />

@@ -192,3 +206,3 @@

theme={{
// Assign theme properties directly
/* Assign theme properties directly */
level0: "#ebedf0",

@@ -195,0 +209,0 @@ level1: "#9be9a8",

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc