Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[ooxast-util-to-unified-latex] do something with the styles #87

Open
github-actions bot opened this issue Mar 2, 2023 · 0 comments
Open

[ooxast-util-to-unified-latex] do something with the styles #87

github-actions bot opened this issue Mar 2, 2023 · 0 comments
Labels

Comments

@github-actions
Copy link

github-actions bot commented Mar 2, 2023

[ooxast-util-to-unified-latex] do something with the styles

const styles = select('w\:styles', node)

if (styles) {

h.styles = all(h, styles)

}

// TODO: [ooxast-util-to-unified-latex] do something with the styles

import { all } from '../all'
import { H, Handle } from '../types'
import { Body, Document, Endnotes, Footnotes } from 'ooxast'
import { select } from 'xast-util-select'
import { notes } from '../util/notes'
import { convertElement } from 'xast-util-is-element'

const isFootnotes = convertElement<Footnotes>('w:footnotes')
const isEndnotes = convertElement<Endnotes>('w:endnotes')

export const document: Handle = (h: H, node: Document) => {
  h.simpleParagraph = true
  const body = select('w\\:body', node)

  const foots = select('w\\:footnotes', node)
  if (foots && isFootnotes(foots)) {
    h.footnotes = notes(h, foots)
  }

  const endnotes = select('w\\:endnotes', node)
  if (endnotes && isEndnotes(endnotes)) {
    h.endnotes = notes(h, endnotes)
  }

  // TODO: [ooxast-util-to-unified-latex] do something with the styles
  // const styles = select('w\\:styles', node)
  // if (styles) {
  //   h.styles = all(h, styles)
  // }

  const relations = select('w\\:relationships', node)

51dd9f72ae3918d8eed612857d20153c7db80d31

@github-actions github-actions bot added the todo label Mar 2, 2023
@tefkah tefkah added rejour Issues related to rejour/ooxast reoff ooxast xast unified-latex labels Mar 14, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant