function r(){try{const r="__storage_test__";localStorage.setItem(r,r);localStorage.removeItem(r);return true}catch(r){return false}}class t{available;constructor(){this.available=r()}get(r){if(!this.available)return null;try{const t=localStorage.getItem(r);return t?JSON.parse(t):null}catch(t){console.warn(`Error getting item ${r} from localStorage:`,t);return null}}set(r,t){if(!this.available)return;try{localStorage.setItem(r,JSON.stringify(t))}catch(t){console.warn(`Error setting item ${r} in localStorage:`,t)}}remove(r){if(!this.available)return;try{localStorage.removeItem(r)}catch(t){console.warn(`Error removing item ${r} from localStorage:`,t)}}clear(){if(!this.available)return;try{localStorage.clear()}catch(r){console.warn("Error clearing localStorage:",r)}}}export{t as L};
//# sourceMappingURL=p-8d78b631.js.map