@redocly/graphql-docs
Version:
Redocly GraphQL docs
2 lines (1 loc) • 576 B
JavaScript
import{jsx as r,jsxs as m}from"react/jsx-runtime";import{useMemo as n,memo as p}from"react";import{Box as a}from"../../common/index.js";import{useStore as s}from"../../app/index.js";import{OperationExample as d}from"../../examples/index.js";import{ExtendedFieldView as f}from"../components/index.js";function u({name:o,path:i}){const e=s(),t=n(()=>e?.getMutationField(o),[o,e]);return t?m(a,{"data-testid":t.name,direction:"row",wrap:"wrap",gap:"64px",children:[r(f,{field:t,path:i}),r(d,{operationType:"mutation",operation:t})]}):null}const g=p(u);export{g as MutationItem};