@optique/core 0.7.16-dev.389 → 0.7.16

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.
@@ -882,6 +882,9 @@ function merge(...args) {
882
882
  });
883
883
  },
884
884
  getDocFragments(state, _defaultValue) {
885
+ let brief;
886
+ let description;
887
+ let footer;
885
888
  const fragments = parsers.flatMap((p, i) => {
886
889
  let parserState;
887
890
  if (p.initialState === void 0) {
@@ -895,7 +898,11 @@ function merge(...args) {
895
898
  kind: "available",
896
899
  state: state.state
897
900
  };
898
- return p.getDocFragments(parserState, void 0).fragments;
901
+ const docFragments = p.getDocFragments(parserState, void 0);
902
+ brief ??= docFragments.brief;
903
+ description ??= docFragments.description;
904
+ footer ??= docFragments.footer;
905
+ return docFragments.fragments;
899
906
  });
900
907
  const entries = fragments.filter((f) => f.type === "entry");
901
908
  const sections = [];
@@ -910,18 +917,28 @@ function merge(...args) {
910
917
  entries
911
918
  };
912
919
  sections.push(labeledSection);
913
- return { fragments: sections.map((s) => ({
920
+ return {
921
+ brief,
922
+ description,
923
+ footer,
924
+ fragments: sections.map((s) => ({
925
+ ...s,
926
+ type: "section"
927
+ }))
928
+ };
929
+ }
930
+ return {
931
+ brief,
932
+ description,
933
+ footer,
934
+ fragments: [...sections.map((s) => ({
914
935
  ...s,
915
936
  type: "section"
916
- })) };
917
- }
918
- return { fragments: [...sections.map((s) => ({
919
- ...s,
920
- type: "section"
921
- })), {
922
- type: "section",
923
- entries
924
- }] };
937
+ })), {
938
+ type: "section",
939
+ entries
940
+ }]
941
+ };
925
942
  }
926
943
  };
927
944
  }
@@ -882,6 +882,9 @@ function merge(...args) {
882
882
  });
883
883
  },
884
884
  getDocFragments(state, _defaultValue) {
885
+ let brief;
886
+ let description;
887
+ let footer;
885
888
  const fragments = parsers.flatMap((p, i) => {
886
889
  let parserState;
887
890
  if (p.initialState === void 0) {
@@ -895,7 +898,11 @@ function merge(...args) {
895
898
  kind: "available",
896
899
  state: state.state
897
900
  };
898
- return p.getDocFragments(parserState, void 0).fragments;
901
+ const docFragments = p.getDocFragments(parserState, void 0);
902
+ brief ??= docFragments.brief;
903
+ description ??= docFragments.description;
904
+ footer ??= docFragments.footer;
905
+ return docFragments.fragments;
899
906
  });
900
907
  const entries = fragments.filter((f) => f.type === "entry");
901
908
  const sections = [];
@@ -910,18 +917,28 @@ function merge(...args) {
910
917
  entries
911
918
  };
912
919
  sections.push(labeledSection);
913
- return { fragments: sections.map((s) => ({
920
+ return {
921
+ brief,
922
+ description,
923
+ footer,
924
+ fragments: sections.map((s) => ({
925
+ ...s,
926
+ type: "section"
927
+ }))
928
+ };
929
+ }
930
+ return {
931
+ brief,
932
+ description,
933
+ footer,
934
+ fragments: [...sections.map((s) => ({
914
935
  ...s,
915
936
  type: "section"
916
- })) };
917
- }
918
- return { fragments: [...sections.map((s) => ({
919
- ...s,
920
- type: "section"
921
- })), {
922
- type: "section",
923
- entries
924
- }] };
937
+ })), {
938
+ type: "section",
939
+ entries
940
+ }]
941
+ };
925
942
  }
926
943
  };
927
944
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@optique/core",
3
- "version": "0.7.16-dev.389+19027a10",
3
+ "version": "0.7.16",
4
4
  "description": "Type-safe combinatorial command-line interface parser",
5
5
  "keywords": [
6
6
  "CLI",