@onsvisual/svelte-components 0.1.7 → 0.1.8

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.
@@ -223,7 +223,7 @@
223
223
 
224
224
  offset = (threshold_px - top) / (bottom - top);
225
225
  if (bottom >= threshold_px) {
226
- if (index !== i || entered) {
226
+ if (index !== i) {
227
227
  index = i;
228
228
  sectionId = section.dataset.id ? section.dataset.id : null;
229
229
  dispatch("change", { id, index, sectionId });
@@ -232,7 +232,10 @@
232
232
  }
233
233
  }
234
234
 
235
- if (entered) dispatch("enter", { id, index, sectionId });
235
+ if (entered) {
236
+ dispatch("enter", { id, index, sectionId });
237
+ dispatch("change", { id, index, sectionId });
238
+ }
236
239
  if (exited) dispatch("exit", { id, index, sectionId });
237
240
  }
238
241
  </script>
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@onsvisual/svelte-components",
3
- "version": "0.1.7",
3
+ "version": "0.1.8",
4
4
  "type": "module",
5
5
  "private": false,
6
6
  "homepage": "https://onsvisual.github.io/svelte-components",