nuxt-outfit 1.0.3 → 1.0.5

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.
package/dist/module.json CHANGED
@@ -1,5 +1,5 @@
1
1
  {
2
2
  "name": "@nuxt/outfit",
3
3
  "configKey": "outfit",
4
- "version": "1.0.3"
4
+ "version": "1.0.5"
5
5
  }
@@ -1,3 +1,4 @@
1
+ import { onMounted, onBeforeUnmount } from "vue";
1
2
  export const useDetectOutsideClick = (component, callback) => {
2
3
  if (!component) {
3
4
  return;
@@ -1,3 +1,4 @@
1
+ import { useNuxtApp } from "#imports";
1
2
  export const useEcho = () => {
2
3
  const { $echo } = useNuxtApp();
3
4
  const notificationNamespace = ".Illuminate\\Notifications\\Events\\BroadcastNotificationCreated";
@@ -1,9 +1,9 @@
1
1
  export declare const useForm: (opts?: {}) => {
2
2
  fields: any;
3
- errors: any;
3
+ errors: import("vue").Ref<{}>;
4
4
  repeatArray: (property: any) => void;
5
5
  removeArray: (property: any, index: any) => void;
6
- isPending: any;
6
+ isPending: import("vue").Ref<boolean>;
7
7
  handleSubmit: () => Promise<void>;
8
8
  clearError: (field: any) => void;
9
9
  reset: () => void;
@@ -1,3 +1,5 @@
1
+ import { ref, reactive } from "vue";
2
+ import { useRuntimeConfig, useNuxtApp, useState } from "#imports";
1
3
  import { klona as deepClone } from "klona/full";
2
4
  import { unflatten } from "flat";
3
5
  import { has, unset } from "lodash-es";
@@ -1,3 +1,4 @@
1
+ import { useRuntimeConfig, useRequestEvent, useRequestHeaders } from "#imports";
1
2
  import { appendHeader } from "h3";
2
3
  import { parse, splitCookiesString as split } from "set-cookie-parser";
3
4
  import { serialize } from "cookie";
@@ -12,7 +13,7 @@ export const useSpaHeaders = (additionalHeaders = {}) => {
12
13
  const headers = useRequestHeaders(["cookie", "referer", "host"]);
13
14
  const goodResponses = [200, 201, 202, 203, 204, 205, 206, 207, 208, 226];
14
15
  if (!Object.prototype.hasOwnProperty.call(headers, "referer")) {
15
- headers.referer = `${headers.host}/${event.req.originalUrl}`;
16
+ headers.referer = `${headers.host}/${event.node.req.originalUrl}`;
16
17
  }
17
18
  const parseCookie = (cookies) => {
18
19
  return parse(split(cookies)).map((cookie) => serialize(cookie.name, cookie.value, cookie));
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "nuxt-outfit",
3
- "version": "1.0.3",
3
+ "version": "1.0.5",
4
4
  "description": "Outfit - Connection Laravel and Nuxt",
5
5
  "repository": {
6
6
  "type": "git",