1.0.0 • Published 6 years ago

dse_public_content_html v1.0.0

Weekly downloads
4
License
ISC
Repository
-
Last release
6 years ago

This file system is statically delivered by a server. To modify and debug please read the sections on dev-server and index.js.

-- dev-server To run dev-server 1.) unzip dev-server.zipx to here. 2.) install gulp globally (npm install --global gulp-cli) 3.) run cmd (npm run gulp)

The server should start with no errors and should serve the files like the application server.

-- index.js This project is set up to be a modular angularJS application. The index file can but should not be modified directly.

There are two "POWERSHELL" scripts that can be used to break down index.js and watch for changes in the broken down files. Thes files are found in the "Expand" folder.

Breakdown.ps1
  Reads index.js and creates the file system described by the comments of
  the form //-- {file name relitive to the Breakdown folder} --//.
  run with: & .\Breakdown.ps1

Watch.ps1
  Watches all js files in the Breakdown folder and bundles them into
  index.js when any of the files are updated.
  run with: & .\Watch.ps1

Run both commands $.\Breakdown.ps1; &.\Watch.ps1
  This is recommened when ever pulling file for the first time since
  index.js could have been updated directly.

-- content.html This html file is used to import html resources in the en and es folder.

URL Parameters: resource - this is the file name, exculding '.html' of the resource you wish to retrieve. It will pull files from both/all the en and es folder if they exist. If both exist - it will display english by default(see lang param) and a link in the upper right will allow you to switch languages.

              If only one exists - The one that exists will be displayed
                regardless of language requested.

              if non exist - an error message will be displayed.

lang - This param will set the "perferred" language of the resource.
  If resource exists in more than one language including the perferred - the
    perferred will be displayed and the other valid laguages can be switched
    two by buttons in the upper right corner.

  If resource dne in perferred language, it will be displayed in the first
    valid language found(see ContentController.js: function show content).

Creating new language Simply add language to the "LANG" array in ConstantService.js and add a import-html tag in the same format as the en and spanish tags, Changing the lang param of course. All functions should be generalized and you are done!

-- css format Css to control 90+ percent of the content is found in style.css, between the /** Rebranding **/ comment at the top of the page.

To rebrand simply open the resource css-format in your browser and then modify all the css to conform the the new style.

1.0.0

6 years ago