lesli_assets 1.0.4 → 1.0.6

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 36ffc1c4deab68fe239126dcca97f8f070a4c70c506a234756a6d82a77201a6b
4
- data.tar.gz: ea1276e1d61fcedc4f8ca6d66da439be4c2a928bb88b1c90a8d6db008162e2f4
3
+ metadata.gz: f234b149b3a20b1da3fb9ae982894cb296e15eb88f0267c0768655bacf9fcd99
4
+ data.tar.gz: 4ca24d6828cb1484e3eead745083597c5945990870bd24b3cbfe02f1194cea5e
5
5
  SHA512:
6
- metadata.gz: ecac2614189028aeaf1bf6634b11cdab9bbf2bae7c716fc553fcfcd378ea4dfa9e4bc63c2a0868771d7b987116d0cb51e48ea60e94b8ff1891c3af913f8d88be
7
- data.tar.gz: 01ea9d92880d93a93a28cd1ee48aecf299430eeb406659710ed819a392c5e2d39d154fbcb2be136b8b38090834230e281834a2e4c36b3618b47ab443b4cf7e80
6
+ metadata.gz: e9f22e3160994d5d830e19648a0fd477cddaa639768e9305de0d3b81338ef697fb40a771432310699001fff3c51a9fe89c3f4f89c0a899b67b5b2c81e105e8a4
7
+ data.tar.gz: 5a1f49a32cd1b999b12c98b233c9a22497e133bdc06df3d8d40a3eba0856343a2c2a472630e3dd8a43e9a571550719f196abbcd0c563e56fbdc04b11bed8e9dd
@@ -8,3 +8,7 @@
8
8
  // · Framework asssets
9
9
  // · ~·~ ~·~ ~·~ ~·~ ~·~ ~·~ ~·~ ~·~ ~·~
10
10
  //= link lesli_assets/templates/application.css
11
+
12
+
13
+ //= link lesli_assets/Domine/Domine-Variable.ttf
14
+ //= link lesli_assets/Remix/remixicon.ttf
@@ -9667,6 +9667,11 @@
9667
9667
  });
9668
9668
 
9669
9669
  // lib/lesli_assets_js/calendar.js
9670
+ function getCalendarInitialView() {
9671
+ if (window.innerWidth < 768) return "dayGridDay";
9672
+ if (window.innerWidth < 1024) return "dayGridWeek";
9673
+ return "dayGridMonth";
9674
+ }
9670
9675
  function buildCalendar() {
9671
9676
  console.log("buildCalendar");
9672
9677
  let calendarEl = document.getElementById("lesli-calendar-engine");
@@ -9676,7 +9681,7 @@
9676
9681
  plugins: [index],
9677
9682
  firstDay: 1,
9678
9683
  headerToolbar: false,
9679
- initialView: "dayGridMonth",
9684
+ initialView: getCalendarInitialView(),
9680
9685
  showNonCurrentDates: true,
9681
9686
  dayMaxEvents: true,
9682
9687
  editable: true,
@@ -9695,6 +9700,12 @@
9695
9700
  });
9696
9701
  console.log("renderCalendar");
9697
9702
  calendar.render();
9703
+ window.addEventListener("resize", () => {
9704
+ const newView = getCalendarInitialView();
9705
+ if (calendar.view.type !== newView) {
9706
+ calendar.changeView(newView);
9707
+ }
9708
+ });
9698
9709
  }
9699
9710
  document.addEventListener("DOMContentLoaded", () => {
9700
9711
  console.log("DOMContentLoaded");