diff --git a/fauna/migrations/2021-02-21T14:23:10.957Z/create-collection-accounts.fql b/fauna/migrations/2021-02-21T14_23_10.957Z/create-collection-accounts.fql similarity index 100% rename from fauna/migrations/2021-02-21T14:23:10.957Z/create-collection-accounts.fql rename to fauna/migrations/2021-02-21T14_23_10.957Z/create-collection-accounts.fql diff --git a/fauna/migrations/2021-02-21T14:23:10.957Z/create-collection-goal_participants.fql b/fauna/migrations/2021-02-21T14_23_10.957Z/create-collection-goal_participants.fql similarity index 100% rename from fauna/migrations/2021-02-21T14:23:10.957Z/create-collection-goal_participants.fql rename to fauna/migrations/2021-02-21T14_23_10.957Z/create-collection-goal_participants.fql diff --git a/fauna/migrations/2021-02-21T14:23:10.957Z/create-collection-goal_updates.fql b/fauna/migrations/2021-02-21T14_23_10.957Z/create-collection-goal_updates.fql similarity index 100% rename from fauna/migrations/2021-02-21T14:23:10.957Z/create-collection-goal_updates.fql rename to fauna/migrations/2021-02-21T14_23_10.957Z/create-collection-goal_updates.fql diff --git a/fauna/migrations/2021-02-21T14:23:10.957Z/create-collection-goals.fql b/fauna/migrations/2021-02-21T14_23_10.957Z/create-collection-goals.fql similarity index 100% rename from fauna/migrations/2021-02-21T14:23:10.957Z/create-collection-goals.fql rename to fauna/migrations/2021-02-21T14_23_10.957Z/create-collection-goals.fql diff --git a/fauna/migrations/2021-02-21T14:23:10.957Z/create-collection-sessions.fql b/fauna/migrations/2021-02-21T14_23_10.957Z/create-collection-sessions.fql similarity index 100% rename from fauna/migrations/2021-02-21T14:23:10.957Z/create-collection-sessions.fql rename to fauna/migrations/2021-02-21T14_23_10.957Z/create-collection-sessions.fql diff --git a/fauna/migrations/2021-02-21T14:23:10.957Z/create-collection-update_comments.fql b/fauna/migrations/2021-02-21T14_23_10.957Z/create-collection-update_comments.fql similarity index 100% rename from fauna/migrations/2021-02-21T14:23:10.957Z/create-collection-update_comments.fql rename to fauna/migrations/2021-02-21T14_23_10.957Z/create-collection-update_comments.fql diff --git a/fauna/migrations/2021-02-21T14:23:10.957Z/create-collection-update_likes.fql b/fauna/migrations/2021-02-21T14_23_10.957Z/create-collection-update_likes.fql similarity index 100% rename from fauna/migrations/2021-02-21T14:23:10.957Z/create-collection-update_likes.fql rename to fauna/migrations/2021-02-21T14_23_10.957Z/create-collection-update_likes.fql diff --git a/fauna/migrations/2021-02-21T14:23:10.957Z/create-collection-user_followers.fql b/fauna/migrations/2021-02-21T14_23_10.957Z/create-collection-user_followers.fql similarity index 100% rename from fauna/migrations/2021-02-21T14:23:10.957Z/create-collection-user_followers.fql rename to fauna/migrations/2021-02-21T14_23_10.957Z/create-collection-user_followers.fql diff --git a/fauna/migrations/2021-02-21T14:23:10.957Z/create-collection-users.fql b/fauna/migrations/2021-02-21T14_23_10.957Z/create-collection-users.fql similarity index 100% rename from fauna/migrations/2021-02-21T14:23:10.957Z/create-collection-users.fql rename to fauna/migrations/2021-02-21T14_23_10.957Z/create-collection-users.fql diff --git a/fauna/migrations/2021-02-21T14:23:10.957Z/create-collection-verification_requests.fql b/fauna/migrations/2021-02-21T14_23_10.957Z/create-collection-verification_requests.fql similarity index 100% rename from fauna/migrations/2021-02-21T14:23:10.957Z/create-collection-verification_requests.fql rename to fauna/migrations/2021-02-21T14_23_10.957Z/create-collection-verification_requests.fql diff --git a/fauna/migrations/2021-02-21T14:30:31.830Z/create-index-account_by_provider_account_id.fql b/fauna/migrations/2021-02-21T14_30_31.830Z/create-index-account_by_provider_account_id.fql similarity index 100% rename from fauna/migrations/2021-02-21T14:30:31.830Z/create-index-account_by_provider_account_id.fql rename to fauna/migrations/2021-02-21T14_30_31.830Z/create-index-account_by_provider_account_id.fql diff --git a/fauna/migrations/2021-02-21T14:30:31.830Z/create-index-all_comments_by_update.fql b/fauna/migrations/2021-02-21T14_30_31.830Z/create-index-all_comments_by_update.fql similarity index 100% rename from fauna/migrations/2021-02-21T14:30:31.830Z/create-index-all_comments_by_update.fql rename to fauna/migrations/2021-02-21T14_30_31.830Z/create-index-all_comments_by_update.fql diff --git a/fauna/migrations/2021-02-21T14:30:31.830Z/create-index-all_goals_by_participant.fql b/fauna/migrations/2021-02-21T14_30_31.830Z/create-index-all_goals_by_participant.fql similarity index 100% rename from fauna/migrations/2021-02-21T14:30:31.830Z/create-index-all_goals_by_participant.fql rename to fauna/migrations/2021-02-21T14_30_31.830Z/create-index-all_goals_by_participant.fql diff --git a/fauna/migrations/2021-02-21T14:30:31.830Z/create-index-all_likes_by_update.fql b/fauna/migrations/2021-02-21T14_30_31.830Z/create-index-all_likes_by_update.fql similarity index 100% rename from fauna/migrations/2021-02-21T14:30:31.830Z/create-index-all_likes_by_update.fql rename to fauna/migrations/2021-02-21T14_30_31.830Z/create-index-all_likes_by_update.fql diff --git a/fauna/migrations/2021-02-21T14:30:31.830Z/create-index-all_participants_by_goal.fql b/fauna/migrations/2021-02-21T14_30_31.830Z/create-index-all_participants_by_goal.fql similarity index 100% rename from fauna/migrations/2021-02-21T14:30:31.830Z/create-index-all_participants_by_goal.fql rename to fauna/migrations/2021-02-21T14_30_31.830Z/create-index-all_participants_by_goal.fql diff --git a/fauna/migrations/2021-02-21T14:30:31.830Z/create-index-all_recent_updates.fql b/fauna/migrations/2021-02-21T14_30_31.830Z/create-index-all_recent_updates.fql similarity index 100% rename from fauna/migrations/2021-02-21T14:30:31.830Z/create-index-all_recent_updates.fql rename to fauna/migrations/2021-02-21T14_30_31.830Z/create-index-all_recent_updates.fql diff --git a/fauna/migrations/2021-02-21T14:30:31.830Z/create-index-all_updates_by_goal.fql b/fauna/migrations/2021-02-21T14_30_31.830Z/create-index-all_updates_by_goal.fql similarity index 100% rename from fauna/migrations/2021-02-21T14:30:31.830Z/create-index-all_updates_by_goal.fql rename to fauna/migrations/2021-02-21T14_30_31.830Z/create-index-all_updates_by_goal.fql diff --git a/fauna/migrations/2021-02-21T14:30:31.830Z/create-index-all_updates_by_goal_and_participant.fql b/fauna/migrations/2021-02-21T14_30_31.830Z/create-index-all_updates_by_goal_and_participant.fql similarity index 100% rename from fauna/migrations/2021-02-21T14:30:31.830Z/create-index-all_updates_by_goal_and_participant.fql rename to fauna/migrations/2021-02-21T14_30_31.830Z/create-index-all_updates_by_goal_and_participant.fql diff --git a/fauna/migrations/2021-02-21T14:30:31.830Z/create-index-session_by_token.fql b/fauna/migrations/2021-02-21T14_30_31.830Z/create-index-session_by_token.fql similarity index 100% rename from fauna/migrations/2021-02-21T14:30:31.830Z/create-index-session_by_token.fql rename to fauna/migrations/2021-02-21T14_30_31.830Z/create-index-session_by_token.fql diff --git a/fauna/migrations/2021-02-21T14:30:31.830Z/create-index-unique_goal_and_participant.fql b/fauna/migrations/2021-02-21T14_30_31.830Z/create-index-unique_goal_and_participant.fql similarity index 100% rename from fauna/migrations/2021-02-21T14:30:31.830Z/create-index-unique_goal_and_participant.fql rename to fauna/migrations/2021-02-21T14_30_31.830Z/create-index-unique_goal_and_participant.fql diff --git a/fauna/migrations/2021-02-21T14:30:31.830Z/create-index-unique_update_user_like.fql b/fauna/migrations/2021-02-21T14_30_31.830Z/create-index-unique_update_user_like.fql similarity index 100% rename from fauna/migrations/2021-02-21T14:30:31.830Z/create-index-unique_update_user_like.fql rename to fauna/migrations/2021-02-21T14_30_31.830Z/create-index-unique_update_user_like.fql diff --git a/fauna/migrations/2021-02-21T14:30:31.830Z/create-index-unique_user_and_follower.fql b/fauna/migrations/2021-02-21T14_30_31.830Z/create-index-unique_user_and_follower.fql similarity index 100% rename from fauna/migrations/2021-02-21T14:30:31.830Z/create-index-unique_user_and_follower.fql rename to fauna/migrations/2021-02-21T14_30_31.830Z/create-index-unique_user_and_follower.fql diff --git a/fauna/migrations/2021-02-21T14:30:31.830Z/create-index-user_by_email.fql b/fauna/migrations/2021-02-21T14_30_31.830Z/create-index-user_by_email.fql similarity index 100% rename from fauna/migrations/2021-02-21T14:30:31.830Z/create-index-user_by_email.fql rename to fauna/migrations/2021-02-21T14_30_31.830Z/create-index-user_by_email.fql diff --git a/fauna/migrations/2021-02-21T14:30:31.830Z/create-index-user_by_username.fql b/fauna/migrations/2021-02-21T14_30_31.830Z/create-index-user_by_username.fql similarity index 100% rename from fauna/migrations/2021-02-21T14:30:31.830Z/create-index-user_by_username.fql rename to fauna/migrations/2021-02-21T14_30_31.830Z/create-index-user_by_username.fql diff --git a/fauna/migrations/2021-02-21T14:30:31.830Z/create-index-verification_request_by_token.fql b/fauna/migrations/2021-02-21T14_30_31.830Z/create-index-verification_request_by_token.fql similarity index 100% rename from fauna/migrations/2021-02-21T14:30:31.830Z/create-index-verification_request_by_token.fql rename to fauna/migrations/2021-02-21T14_30_31.830Z/create-index-verification_request_by_token.fql diff --git a/fauna/migrations/2021-02-25T06:56:23.853Z/create-collection-comment_likes.fql b/fauna/migrations/2021-02-25T06_56_23.853Z/create-collection-comment_likes.fql similarity index 100% rename from fauna/migrations/2021-02-25T06:56:23.853Z/create-collection-comment_likes.fql rename to fauna/migrations/2021-02-25T06_56_23.853Z/create-collection-comment_likes.fql diff --git a/fauna/migrations/2021-02-25T06:56:23.853Z/create-index-all_likes_by_comment.fql b/fauna/migrations/2021-02-25T06_56_23.853Z/create-index-all_likes_by_comment.fql similarity index 100% rename from fauna/migrations/2021-02-25T06:56:23.853Z/create-index-all_likes_by_comment.fql rename to fauna/migrations/2021-02-25T06_56_23.853Z/create-index-all_likes_by_comment.fql diff --git a/fauna/migrations/2021-02-25T06:56:23.853Z/create-index-unique_comment_user_like.fql b/fauna/migrations/2021-02-25T06_56_23.853Z/create-index-unique_comment_user_like.fql similarity index 100% rename from fauna/migrations/2021-02-25T06:56:23.853Z/create-index-unique_comment_user_like.fql rename to fauna/migrations/2021-02-25T06_56_23.853Z/create-index-unique_comment_user_like.fql diff --git a/fauna/migrations/2021-02-27T20:33:58.638Z/create-collection-activities.fql b/fauna/migrations/2021-02-27T20_33_58.638Z/create-collection-activities.fql similarity index 100% rename from fauna/migrations/2021-02-27T20:33:58.638Z/create-collection-activities.fql rename to fauna/migrations/2021-02-27T20_33_58.638Z/create-collection-activities.fql diff --git a/fauna/migrations/2021-02-27T20:33:58.638Z/create-collection-notifications.fql b/fauna/migrations/2021-02-27T20_33_58.638Z/create-collection-notifications.fql similarity index 100% rename from fauna/migrations/2021-02-27T20:33:58.638Z/create-collection-notifications.fql rename to fauna/migrations/2021-02-27T20_33_58.638Z/create-collection-notifications.fql diff --git a/fauna/migrations/2021-02-27T20:33:58.638Z/create-index-all_notifications_by_user.fql b/fauna/migrations/2021-02-27T20_33_58.638Z/create-index-all_notifications_by_user.fql similarity index 100% rename from fauna/migrations/2021-02-27T20:33:58.638Z/create-index-all_notifications_by_user.fql rename to fauna/migrations/2021-02-27T20_33_58.638Z/create-index-all_notifications_by_user.fql diff --git a/fauna/migrations/2021-02-28T03:12:40.528Z/create-collection-notification_statuses.fql b/fauna/migrations/2021-02-28T03_12_40.528Z/create-collection-notification_statuses.fql similarity index 100% rename from fauna/migrations/2021-02-28T03:12:40.528Z/create-collection-notification_statuses.fql rename to fauna/migrations/2021-02-28T03_12_40.528Z/create-collection-notification_statuses.fql diff --git a/fauna/migrations/2021-02-28T03:12:40.528Z/create-index-notification_status_by_user.fql b/fauna/migrations/2021-02-28T03_12_40.528Z/create-index-notification_status_by_user.fql similarity index 100% rename from fauna/migrations/2021-02-28T03:12:40.528Z/create-index-notification_status_by_user.fql rename to fauna/migrations/2021-02-28T03_12_40.528Z/create-index-notification_status_by_user.fql diff --git a/package.json b/package.json index 1087199..dae43c2 100644 --- a/package.json +++ b/package.json @@ -25,7 +25,6 @@ "@mdx-js/react": "1.6.22", "@tailwindcss/line-clamp": "0.2.0", "classnames": "2.2.6", - "fauna-schema-migrate": "0.1.10", "faunadb": "4.1.0", "luxon": "1.26.0", "markdown-to-jsx": "7.1.1", @@ -68,6 +67,7 @@ "eslint-plugin-prettier": "3.3.1", "eslint-plugin-react": "7.22.0", "eslint-plugin-react-hooks": "4.2.0", + "fauna-schema-migrate": "2.1.0", "husky": "4", "lint-staged": "10.5.4", "npm-run-all": "4.1.5", diff --git a/src/utils/fauna.ts b/src/utils/fauna.ts index a72e284..5e0003a 100644 --- a/src/utils/fauna.ts +++ b/src/utils/fauna.ts @@ -3,21 +3,19 @@ import faunadb from 'faunadb' import { User } from 'src/pages/members' const q = faunadb.query -export function getUserFromUserRef({ - ref, +function isFollowingUser({ session, + userRef, }: { - ref: Expr session: any + userRef: Expr }) { - const userDoc = q.Get(ref) - const userId = q.Select(['ref', 'id'], userDoc) let isFollowing = false if (session) { const followerId = (session.user as User).id const ref = q.Match(q.Index('unique_user_and_follower'), [ - q.Ref(q.Collection('users'), userId), + userRef, q.Ref(q.Collection('users'), followerId), ]) isFollowing = q.If( @@ -26,6 +24,20 @@ export function getUserFromUserRef({ false ) as boolean } + return isFollowing +} + +export function getUserFromUserRef({ + ref, + session, +}: { + ref: Expr + session: any +}) { + const userDoc = q.Get(ref) + const userId = q.Select(['ref', 'id'], userDoc) + const isFollowing = isFollowingUser({ session, userRef: ref }) + return { id: userId, name: q.Select(['data', 'name'], userDoc, null), @@ -40,27 +52,18 @@ export function getUserFromUserRef({ } } -export function getUpdateFromUpdateRef({ - ref: goalUpdateRef, +function hasLikedUpdate({ session, + goalUpdateRef, }: { - ref: Expr session: any + goalUpdateRef: Expr }) { - const goalUpdateDoc = q.Get(goalUpdateRef) - const goalDoc = q.Get(q.Select(['data', 'goal'], goalUpdateDoc)) - const postedByDoc = q.Get(q.Select(['data', 'postedBy'], goalUpdateDoc)) - const description = q.Select(['data', 'description'], goalUpdateDoc) - - const createdAt = q.ToMillis( - q.Select(['data', 'timestamps', 'createdAt'], goalUpdateDoc) - ) - const updateId = q.Select(['ref', 'id'], goalUpdateDoc) let hasLiked = false if (session) { const userId = (session.user as User).id const ref = q.Match(q.Index('unique_update_user_like'), [ - q.Ref(q.Collection('goal_updates'), updateId), + goalUpdateRef, q.Ref(q.Collection('users'), userId), ]) hasLiked = q.If( @@ -69,48 +72,118 @@ export function getUpdateFromUpdateRef({ false ) as boolean } + return hasLiked +} + +function hasLikedComment({ + commentRef, + session, +}: { + commentRef: Expr + session: any +}) { + let hasLiked = false + if (session) { + const userId = (session.user as User).id + const ref = q.Match(q.Index('unique_comment_user_like'), [ + commentRef, + q.Ref(q.Collection('users'), userId), + ]) + hasLiked = q.If( + q.Exists(ref), + q.Select(['data', 'liked'], q.Get(ref)), + false + ) as boolean + } + return hasLiked +} + +function getAllUsersWhoLikedUpdate({ + goalUpdateRef, + session, +}: { + goalUpdateRef: Expr + session: any +}) { + return q.Map( + q.Filter( + q.Paginate(q.Match(q.Index('all_likes_by_update'), goalUpdateRef)), + (updateLikeRef) => q.Select(['data', 'liked'], q.Get(updateLikeRef)) + ), + (likeRef) => + getUserFromUserRef({ + ref: q.Select(['data', 'user'], q.Get(likeRef)), + session, + }) + ) +} + +function getAllUsersWhoLikedComment({ + commentRef, + session, +}: { + commentRef: Expr + session +}) { + return q.Map( + q.Filter( + q.Paginate(q.Match(q.Index('all_likes_by_comment'), commentRef)), + (commentLikeRef) => { + return q.Select(['data', 'liked'], q.Get(commentLikeRef)) + } + ), + (likeRef) => + getUserFromUserRef({ + ref: q.Select(['data', 'user'], q.Get(likeRef)), + session, + }) + ) +} + +function getAllCommentsOfUpdate({ + goalUpdateRef, + session, +}: { + goalUpdateRef: Expr + session: any +}) { + return q.Map( + q.Paginate(q.Match(q.Index('all_comments_by_update'), goalUpdateRef)), + (commentRef) => getCommentFromCommentRef({ ref: commentRef, session }) + ) +} + +export function getUpdateFromUpdateRef({ + ref: goalUpdateRef, + session, +}: { + ref: Expr + session: any +}) { + const goalUpdateDoc = q.Get(goalUpdateRef) + const goalDoc = q.Get(q.Select(['data', 'goal'], goalUpdateDoc)) + const postedByDoc = q.Get(q.Select(['data', 'postedBy'], goalUpdateDoc)) + const description = q.Select(['data', 'description'], goalUpdateDoc) + const createdAt = q.ToMillis( + q.Select(['data', 'timestamps', 'createdAt'], goalUpdateDoc) + ) + const updateId = q.Select(['ref', 'id'], goalUpdateDoc) + const hasLiked = hasLikedUpdate({ goalUpdateRef, session }) return { id: updateId, goal: { id: q.Select(['ref', 'id'], goalDoc), title: q.Select(['data', 'title'], goalDoc), }, - comments: q.Map( - q.Paginate(q.Match(q.Index('all_comments_by_update'), goalUpdateRef)), - (commentRef) => { - return getCommentFromCommentRef({ ref: commentRef, session }) - } - ), + comments: getAllCommentsOfUpdate({ goalUpdateRef, session }), hasLiked, - likes: q.Map( - q.Filter( - q.Paginate(q.Match(q.Index('all_likes_by_update'), goalUpdateRef)), - (updateLikeRef) => { - return q.Select(['data', 'liked'], q.Get(updateLikeRef)) - } - ), - (likeRef) => { - const likeDoc = q.Get(likeRef) - const userRef = q.Select(['data', 'user'], likeDoc) - - return getUserFromUserRef({ ref: userRef, session }) - } - ), + likes: getAllUsersWhoLikedUpdate({ goalUpdateRef, session }), description, createdAt, - postedBy: { - id: q.Select(['ref', 'id'], postedByDoc), - name: q.Select(['data', 'name'], postedByDoc, null), - image: q.Select(['data', 'image'], postedByDoc, null), - username: q.Select(['data', 'username'], postedByDoc, null), - account: { - firstName: q.Select( - ['data', 'account', 'firstName'], - postedByDoc, - null - ), - }, - }, + postedBy: getUserFromUserRef({ + ref: q.Select(['ref'], postedByDoc), + session, + }), } } @@ -123,53 +196,19 @@ export function getCommentFromCommentRef({ }) { const commentDoc = q.Get(commentRef) const postedByDoc = q.Get(q.Select(['data', 'postedBy'], commentDoc)) - let hasLiked = false - const commentId = q.Select(['ref', 'id'], commentDoc) - if (session) { - const userId = (session.user as User).id - const ref = q.Match(q.Index('unique_comment_user_like'), [ - q.Ref(q.Collection('update_comments'), commentId), - q.Ref(q.Collection('users'), userId), - ]) - hasLiked = q.If( - q.Exists(ref), - q.Select(['data', 'liked'], q.Get(ref)), - false - ) as boolean - } + const hasLiked = hasLikedComment({ commentRef, session }) return { - id: commentId, + id: q.Select(['ref', 'id'], commentDoc), updateId: q.Select(['data', 'update', 'id'], commentDoc), description: q.Select(['data', 'description'], commentDoc), createdAt: q.ToMillis( q.Select(['data', 'timestamps', 'createdAt'], commentDoc) ), hasLiked, - likes: q.Map( - q.Filter( - q.Paginate(q.Match(q.Index('all_likes_by_comment'), commentRef)), - (commentLikeRef) => { - return q.Select(['data', 'liked'], q.Get(commentLikeRef)) - } - ), - (likeRef) => { - const likeDoc = q.Get(likeRef) - const userRef = q.Select(['data', 'user'], likeDoc) - return getUserFromUserRef({ ref: userRef, session }) - } - ), - postedBy: { - id: q.Select(['ref', 'id'], postedByDoc), - name: q.Select(['data', 'name'], postedByDoc, null), - image: q.Select(['data', 'image'], postedByDoc, null), - username: q.Select(['data', 'username'], postedByDoc, null), - account: { - firstName: q.Select( - ['data', 'account', 'firstName'], - postedByDoc, - null - ), - }, - }, + likes: getAllUsersWhoLikedComment({ commentRef, session }), + postedBy: getUserFromUserRef({ + ref: q.Select(['ref'], postedByDoc), + session, + }), } } diff --git a/tailwind.config.js b/tailwind.config.js index 7a31367..f92000e 100644 --- a/tailwind.config.js +++ b/tailwind.config.js @@ -9,7 +9,7 @@ module.exports = { theme: { nightwind: { typography: true, - colorClasses: ['placeholder', 'divide'], + colorClasses: ['placeholder', 'divide', 'ring', 'ring-offset'], }, fontFamily: { sans: ['Inter', ...fontFamily.sans], diff --git a/yarn.lock b/yarn.lock index a7d42c6..387886e 100644 --- a/yarn.lock +++ b/yarn.lock @@ -2731,10 +2731,10 @@ fastq@^1.6.0: dependencies: reusify "^1.0.4" -fauna-schema-migrate@0.1.10: - version "0.1.10" - resolved "https://registry.yarnpkg.com/fauna-schema-migrate/-/fauna-schema-migrate-0.1.10.tgz#7aee55d25942d1811c0eba03400c7973de8d22c1" - integrity sha512-V8yi7ketlHyKQe2dFaNynLgdUJ0QH/1MybsHnTaUhYLLB8T02FFWWB5uto/uretYzp5bn1wdJM4LcCLgrs38YQ== +fauna-schema-migrate@2.1.0: + version "2.1.0" + resolved "https://registry.yarnpkg.com/fauna-schema-migrate/-/fauna-schema-migrate-2.1.0.tgz#3d55d532481725ef7e057a824c8a210362e98f53" + integrity sha512-VZSkttVtTHHzP+ngJ4EUo7tjZdsMmWzKAhyorEfrfcchnifaPkFMs2+YyJWoKKOTyFfAtT9GaYqqd7jHe/3TIQ== dependencies: "@babel/parser" "^7.12.7" "@types/deep-equal" "^1.0.1" @@ -2765,10 +2765,10 @@ fauna-schema-migrate@0.1.10: ink-syntax-highlight "^1.0.1" js-beautify "^1.13.0" lodash.clonedeep "^4.5.0" - prettier "^2.2.1" react ">=16.8.2" react-hookstore "^1.5.1" shelljs "^0.8.4" + uuid "^8.3.2" faunadb@4.1.0: version "4.1.0" @@ -5210,7 +5210,7 @@ prettier-linter-helpers@^1.0.0: dependencies: fast-diff "^1.1.2" -prettier@2.2.1, prettier@^2.2.1: +prettier@2.2.1: version "2.2.1" resolved "https://registry.yarnpkg.com/prettier/-/prettier-2.2.1.tgz#795a1a78dd52f073da0cd42b21f9c91381923ff5" integrity sha512-PqyhM2yCjg/oKkFPtTGUojv7gnZAoG80ttl45O6x2Ug/rMJw4wcc9k6aaf2hibP7BGVCCM33gZoGjyvt9mm16Q== @@ -6716,6 +6716,11 @@ util@^0.11.0: dependencies: inherits "2.0.3" +uuid@^8.3.2: + version "8.3.2" + resolved "https://registry.yarnpkg.com/uuid/-/uuid-8.3.2.tgz#80d5b5ced271bb9af6c445f21a1a04c606cefbe2" + integrity sha512-+NYs2QeMWy+GWFOEm9xnn6HCDp0l7QBD7ml8zLUmJ+93Q5NF0NocErnwkTkXVFNiX3/fpC6afS8Dhb/gz7R7eg== + v8-compile-cache@^2.0.3: version "2.2.0" resolved "https://registry.yarnpkg.com/v8-compile-cache/-/v8-compile-cache-2.2.0.tgz#9471efa3ef9128d2f7c6a7ca39c4dd6b5055b132"