"use strict";Object.defineProperty(exports, "__esModule", {value: true});

var _chunk7K74W2G3js = require('./chunk-7K74W2G3.js');



var _chunkSQA7G4TEjs = require('./chunk-SQA7G4TE.js');


var _chunk6C3VEZWHjs = require('./chunk-6C3VEZWH.js');

// src/Store.ts
var Store_exports = {};
_chunk6C3VEZWHjs.__export.call(void 0, Store_exports, {
  Comonad: () => Comonad,
  Functor: () => Functor,
  URI: () => URI,
  duplicate: () => duplicate,
  experiment: () => experiment,
  extend: () => extend,
  extract: () => extract,
  flap: () => flap2,
  map: () => map,
  peeks: () => peeks,
  seek: () => seek,
  seeks: () => seeks,
  store: () => store
});
function seek(s) {
  return (wa) => ({ peek: wa.peek, pos: s });
}
function seeks(f) {
  return (wa) => ({ peek: wa.peek, pos: f(wa.pos) });
}
function peeks(f) {
  return (wa) => wa.peek(f(wa.pos));
}
function experiment(F) {
  return (f) => (wa) => F.map(f(wa.pos), (s) => wa.peek(s));
}
var _map = (fa, f) => _chunkSQA7G4TEjs.pipe.call(void 0, fa, map(f));
var _extend = (wa, f) => _chunkSQA7G4TEjs.pipe.call(void 0, wa, extend(f));
var extend = (f) => (wa) => ({
  peek: (s) => f({ peek: wa.peek, pos: s }),
  pos: wa.pos
});
var extract = (wa) => wa.peek(wa.pos);
var duplicate = /* @__PURE__ */ extend(_chunkSQA7G4TEjs.identity);
var map = (f) => (fa) => ({
  peek: (s) => f(fa.peek(s)),
  pos: fa.pos
});
var URI = "Store";
var Functor = {
  URI,
  map: _map
};
var flap2 = /* @__PURE__ */ _chunk7K74W2G3js.flap.call(void 0, Functor);
var Comonad = {
  URI,
  map: _map,
  extend: _extend,
  extract
};
var store = Comonad;
















exports.seek = seek; exports.seeks = seeks; exports.peeks = peeks; exports.experiment = experiment; exports.extend = extend; exports.extract = extract; exports.duplicate = duplicate; exports.map = map; exports.URI = URI; exports.Functor = Functor; exports.flap = flap2; exports.Comonad = Comonad; exports.store = store; exports.Store_exports = Store_exports;
