UNPKG

@redocly/graphql-docs

Version:

Redocly GraphQL docs

2 lines (1 loc) 588 B
import{jsx as e,jsxs as p}from"react/jsx-runtime";import{memo as n,useMemo as s}from"react";import{Box as m}from"../../common/index.js";import{useStore as a}from"../../app/index.js";import{OperationExample as c}from"../../examples/index.js";import{ExtendedFieldView as d}from"../components/index.js";function f({name:t,path:i}){const r=a(),o=s(()=>r?.getSubscriptionField(t),[t,r]);return o?p(m,{"data-testid":o.name,direction:"row",wrap:"wrap",gap:"64px",children:[e(d,{field:o,path:i}),e(c,{operationType:"subscription",operation:o})]}):null}const S=n(f);export{S as SubscriptionItem};