Giter Club home page Giter Club logo

stylesheets's Introduction

Lantana Stylesheets

This is a repository to store any stylesheets developed and released by Lantana.

CDA Stylesheet

Introduction

This folder contains the Lantana CDA stylesheet, an open-source renderer for CDA documents. The stylesheet transforms the XML of a CDA document into a webpage that can be viewed in a browser or other XSLT-compatible application.

Some Features

  • Adapt to any device, including paper (responsive)
  • Drag and drop re-ordering of sections from the Table of Contents
  • Indicate context by highlighting current section while navigating
  • Map common header identifiers to human readable display text (mostly US)
  • Logical grouping, revamped color palette, clearer text

Overview of Files

Development Files

Stylesheet Files

The stylesheet files are separated to make maintenance and development easier. They are combined into distribution files for packaging and using in production.

./cda.xsl                   The main transformation, depends on cda-style.xsl and cda-js-dependencies.xsl
./cda-style.xsl             Contains CSS and custom Javascript
./cda-js-dependencies.xsl   Contains Fixed Libraries. Referenced for offline viewing

Build Files

The build files are used to combine the development stylesheet files into the distribution files

./build.xml                 An ANT file that when executed combines the files and outputs the two distribution files
./compile.xsl               A transformation which performs the actual combination of the xsl files. 

Distribution Files

./dist/cda.xsl              All development files compiled into a single file. Useful for standalone offline rendering.
./dist/cda-web.xsl          All development files compiled into a single file with web references to the fixed libraries. Useful for rendering while connected to the internet.

Installation

No installation necessary. It is recommended to use the distribution files because it's easier to work with a single standalone file vs. multiple referenced files.

Use

Simply reference the stylesheet in the XML file and open the XML file in Internet Explorer (Edge or older IE). To use the navigation features, select "Allow blocked content"

<?xml-stylesheet type="text/xsl" href="./cda.xsl"?>

Alternatively use an XSLT transformation engine and save the output as an HTML document. The resulting document in your browser of choice. The output is confirmed to work on Chrome, Internet Explorer (Edge or Older) and Firefox.

stylesheets's People

Contributors

ericparapini-lantanagroup avatar minigrrl avatar seanmcilvenna avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

stylesheets's Issues

how to use this project

I now have a cda document xml, if you want to use this tool to generate a html, how should I operate, after reading the readme did not understand the use of the way, can answer a little, thank you very much!

styleCode attribute causes stylesheet not to render contained content

There is a bug in your current CDA.xsl such that if a styleCode is specified on a structure element like

then the structure isn't included. Meaning that the table definition (shown below) ends up being just text with no formatting. Since MCV is big on styleCodes I would hope they wouldn't just be dropped, or the elements that include them be dropped because they aren't the 3 standard, Italics, Underline, Bold.

            <table styleCode=\"xBorderBottom\">
              <colgroup>
                <col width=\"50%\" />
                <col width=\"50%\" />
              </colgroup>
              <tbody>
                <tr>
                  <td>
                    <content>Actors (Management, Business, Science, and Arts Occupations)</content>
                    <br/>
                    <content styleCode=\"xSecondary\">21-Apr-1985 0:00</content>
                    <content styleCode=\"xLabel xSecondary\"> To </content>
                    <content styleCode=\"xSecondary\">23-Jun-2016 0:00</content>
                  </td>
                  <td>
                    <content>Motion pictures and video industries (Information)</content>
                    <br />
                    <content styleCode=\"xSecondary\">21-Apr-1985 0:00</content>
                    <content styleCode=\"xLabel xSecondary\"> To </content>
                    <content styleCode=\"xSecondary\">23-Jun-2016 0:00</content>
                  </td>
                </tr>
              </tbody>
            </table>

Author doesn't render if it's a device rather than a person

This leaves author blank:

  <author>
      <time value="20161107094421+0000"/>
      <!--Author/authenticator may be software or may be a provider such as
            "infection control professional".-->
      <assignedAuthor><!--Id for authoring device - made up application OID-->
         <id root="2.16.840.1.113883.3.72.5.20"/>
         <!--authoring device address - may or may not be same as facility where care provided for case-->
         <addr>
            <streetAddressLine>4646 Brown Rd</streetAddressLine>
            <city>Salem</city>
            <state>MA</state>
            <postalCode>02368</postalCode>
            <country>US</country>
         </addr>
         <telecom use="WP" value="tel:+1-(555)555-1212;ext=9998"/>
         <assignedAuthoringDevice>
                <manufacturerModelName displayName="Acme"/>
                <softwareName displayName="Acme EHR"/>
            </assignedAuthoringDevice>
      </assignedAuthor>
   </author>

Need default for Document Type

If the ClinicalDocument/code isn't in the specific list of codes mapped in translate-doc-type, then Document Type is blank.

Add default for Document Type - maybe code/@DisplayName first and if that doesn't exist so generic text or even ClinicalDocument/title.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.