3.1.0-rc.12-no-files • Published 1 year ago

@opendesign/octopus-psd v3.1.0-rc.12-no-files

Weekly downloads
-
License
Apache-2.0
Repository
-
Last release
1 year ago

Octopus Converter for Photoshop

Adobe Photoshop to Octopus 3 converter.

Install

yarn add @opendesign/octopus-psd

.env variables

If missing .env file, make a copy of .env.example and rename it to .env and fill correct info.

VariableTypeDescription
NODE_ENVproduction / development / debugNode environment
LOG_LEVELfatal / error / warn / info / debug / trace / silentLog level

Usage

There are three main processing steps:

  • reading source data (using readers)
  • conversion (using convertor with SourceDesign instance produced by reader)
  • exporting (using exporters)

Although you can define the way of reading assets or exporting results yourself (create your own reader/exporter class), you can also choose between existing ones.

Check examples/node/convert-psd-local.ts for example usage in automated runs.

Check examples/node/convert-psd-debug.ts for example usage in custom manual runs.

Check src/services/exporters/ for more details about exporters.

Check src/services/readers/ for more details about readers


Demo: Node Examples

.env demo variables

ENV variables for our demo scripts located in /examples/node/*

VariableTypeDescription
SHOULD_RENDERbooleanif true will trigger ODE rendering when octopus3.json is ready
ODE_RENDERER_CMDstringpath to ODE rendering command (e.g. orchestrator4.run)
ODE_IGNORE_VALIDATIONbooleanignores the ODE rendering validation
FONTS_PATHstringpath to directory with fonts

Convert .PSD file

yarn convert:psd:debug

Designed for manual runs.

yarn convert:psd:debug sample/some-file.psd

When it receives directory as parameter, it will convert all photoshop files located there.

yarn convert:psd:debug sample

yarn convert:psd:local

Designed for running in automated runs.

yarn convert:psd:local sample/some-file.psd

TypeDoc

Command yarn typedoc will generate TypeDoc documentation for public Classes into ./docs folder


Tests

yarn test

Runs Unit & Integration tests.

Unit Tests

yarn test:unit

Runs Unit tests using Jest framework.

Integration Tests

yarn test:integration

Runs Integration tests using our custom framework. Tries to convert octopus components + manifest for saved designs and compares them using jsondiffpatch with saved expected output.

3.1.0-rc.10

1 year ago

3.1.0-rc.12

1 year ago

3.1.0-rc.11

1 year ago

3.1.0-rc.6

1 year ago

3.1.0-rc.7

1 year ago

3.1.0-rc.5

1 year ago

3.1.0-rc.8

1 year ago

3.1.0-rc.9

1 year ago

3.1.0-rc.2

1 year ago

3.1.0-rc.3

1 year ago

3.1.0-rc.1

1 year ago

3.1.0-rc.4

1 year ago

3.0.0-rc.10

1 year ago

3.0.0-rc.9

1 year ago

3.0.0-rc.8

1 year ago

3.0.0-rc.7

2 years ago

3.0.0-rc.6

2 years ago

3.0.0-rc.5

2 years ago