Skip to content

Commit

Permalink
Merge branch 'development'
Browse files Browse the repository at this point in the history
  • Loading branch information
jecisc committed Oct 11, 2019
2 parents 7e127fe + 5dd1839 commit 6f298e0
Show file tree
Hide file tree
Showing 12 changed files with 303 additions and 197 deletions.
8 changes: 3 additions & 5 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,13 +3,11 @@ sudo: false

os:
- linux
- osx

smalltalk:
- Pharo-7.0
- Pharo64-8.0
- Pharo64-7.0
- Pharo-6.1

matrix:
fast_finish: true
allow_failures:
- smalltalk: Pharo-7.0
fast_finish: true
21 changes: 21 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
<!--
git log --pretty="* %s ([%h](https://github.com/DuneSt/PrismCodeDisplayer/commit/%H))" v1.0.1...HEAD --grep="Merge pull"
'Content' copyWithRegex: 'Merge pull request #[0-9]+ from [^/]+/[0-9]*' matchesReplacedWith: '') copyReplaceAll: '-' with: ' '
-->


# [v1.1.0](https://github.com/DuneSt/PrismCodeDisplayer/compare/v1.0.1...v1.1.0) (2019-10-11)


## Features

* Add an integration with Material Design Lite ([b32e139](https://github.com/DuneSt/PrismCodeDisplayer/commit/b32e139f5477e8ce5e7d565294fc53333b9b48d6))

## Infrastructure

* Update to prism 1 17 ([5d99ed8](https://github.com/DuneSt/PrismCodeDisplayer/commit/5d99ed86554132760cb34c8d44a273d536bb5456))
* Use STONJSON instead of NeoJSON ([69a1954](https://github.com/DuneSt/PrismCodeDisplayer/commit/69a1954207c36fcc190428fa7db55bd5dd298c31))
* Do not load all seaside ([85ec0c5](https://github.com/DuneSt/PrismCodeDisplayer/commit/85ec0c59a1470aac1dba8d735edbe12b0a56a2d2))
* Pharo 8 support ([c9d6015](https://github.com/DuneSt/PrismCodeDisplayer/commit/c9d601598d41f44a02ba381f3d2ab09986d1cebb))
14 changes: 7 additions & 7 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,10 +4,6 @@

Master:[![Build Status](https://travis-ci.org/DuneSt/PrismCodeDisplayer.svg?branch=master)](https://travis-ci.org/DuneSt/PrismCodeDisplayer) | Development: [![Build Status](https://travis-ci.org/DuneSt/PrismCodeDisplayer.svg?branch=development)](https://travis-ci.org/DuneSt/PrismCodeDisplayer)

#### Windows builds

Master: [![Build status](https://ci.appveyor.com/api/projects/status/hobn9e8elv13g0if/branch/master?svg=true)](https://ci.appveyor.com/project/jecisc/prismcodedisplayer/branch/master) | Last Commit: [![Build status](https://ci.appveyor.com/api/projects/status/hobn9e8elv13g0if?svg=true)](https://ci.appveyor.com/project/jecisc/prismcodedisplayer)

This project is an implementation of Prism.js in Seaside with a model associated.

# Documentation
Expand Down Expand Up @@ -59,6 +55,10 @@ To use Prism for Seaside you will need to add JQuery and Prism libraries to your
addLibrary: JQDeploymentLibrary
```

## Material Design Lite integration

An integration package with [Material Design Lite](https://github.com/DuneSt/MaterialDesignLite) is available by loading the `mdl` group from Prism's baseline.

## Examples

You can find multiple examples when the application will be installed at the url: [http://localhost:8080/PrismDemo](http://localhost:8080/PrismDemo)
Expand All @@ -69,14 +69,14 @@ You can find a demo at: [https://demos.ferlicot.fr/PrismDemo](https://demos.ferl

## Latest supported Dependency

- [Prism v1.14.0](https://github.com/PrismJS/prism/releases/tag/v1.14.0)
- [Prism v1.17.1](https://github.com/PrismJS/prism/releases/tag/v1.17.1)

## Smalltalk versions compatibility

| Prism version | Compatible Pharo versions |
|--------------- |--------------------------- |
| v1.0.0 | Pharo 61 |
| development | Pharo 61 |
| v1.x.x | Pharo 61, 70, 80 |
| development | Pharo 61, 70, 80 |

## Contact

Expand Down
28 changes: 0 additions & 28 deletions appveyor.yml

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -13,37 +13,42 @@ BaselineOfPrismCodeDisplayer >> baseline: spec [
spec
for: #common
do: [

"Dependencies"
self
seaside3: spec;
neoJSON: spec;
mocketry: spec.
materialDesignLite: spec;
mocketry: spec;
seaside3: spec.

"Packages"
spec
package: 'PrismCodeDisplayer-Core' with: [ spec requires: #('NeoJSON' 'PrismCodeDisplayer-Library') ];
package: 'PrismCodeDisplayer-Core' with: [ spec requires: #('PrismCodeDisplayer-Library') ];
package: 'PrismCodeDisplayer-Library' with: [ spec requires: #('Seaside3') ];
package: 'PrismCodeDisplayer-Demo' with: [ spec requires: #('PrismCodeDisplayer-Core') ];
package: 'PrismCodeDisplayer-Core-Tests' with: [ spec requires: #('PrismCodeDisplayer-Core' 'Mocketry') ].
package: 'PrismCodeDisplayer-Core-Tests' with: [ spec requires: #('PrismCodeDisplayer-Core' 'Mocketry') ];
package: 'PrismCodeDisplayer-MaterialDesignLite' with: [ spec requires: #('PrismCodeDisplayer-Core' 'MaterialDesignLite') ].

"Groups"
spec
group: 'all' with: #('default');
group: 'all' with: #('default' 'mdl');
group: 'core' with: #('PrismCodeDisplayer-Core');
group: 'default' with: #('core' 'demo' 'tests');
group: 'demo' with: #('PrismCodeDisplayer-Demo');
group: 'mdl' with: #('PrismCodeDisplayer-MaterialDesignLite');
group: 'tests' with: #('PrismCodeDisplayer-Core-Tests') ]
]

{ #category : #dependencies }
BaselineOfPrismCodeDisplayer >> mocketry: spec [
spec baseline: 'Mocketry' with: [ spec repository: 'github://dionisiydk/Mocketry:v4.0.x' ]
BaselineOfPrismCodeDisplayer >> materialDesignLite: spec [
spec
baseline: 'MaterialDesignLite'
with: [ spec
loads: #('core');
repository: 'github://DuneSt/MaterialDesignLite:v2.x.x/src' ]
]

{ #category : #dependencies }
BaselineOfPrismCodeDisplayer >> neoJSON: spec [
spec baseline: 'NeoJSON' with: [ spec repository: 'github://svenvc/NeoJSON:v17/repository' ]
BaselineOfPrismCodeDisplayer >> mocketry: spec [
spec baseline: 'Mocketry' with: [ spec repository: 'github://dionisiydk/Mocketry:v6.0.x' ]
]

{ #category : #accessing }
Expand All @@ -55,5 +60,9 @@ BaselineOfPrismCodeDisplayer >> projectClass [

{ #category : #dependencies }
BaselineOfPrismCodeDisplayer >> seaside3: spec [
spec baseline: 'Seaside3' with: [ spec repository: 'github://SeasideSt/Seaside/repository' ]
spec
baseline: 'Seaside3'
with: [ spec
loads: #('Core' 'JQuery' 'Zinc');
repository: 'github://SeasideSt/Seaside:v3.4.x/repository' ]
]
18 changes: 9 additions & 9 deletions src/PrismCodeDisplayer-Core/Color.extension.st
Original file line number Diff line number Diff line change
Expand Up @@ -5,13 +5,13 @@ Color >> asRGBA: anAlpha [
^ String
streamContents: [ :s |
s
<< 'rgba(';
<< (self red * 255) asInteger;
<< $,;
<< (self green * 255) asInteger;
<< $,;
<< (self blue * 255) asInteger;
<< $,;
<< anAlpha asString;
<< $) ]
nextPutAll: 'rgba(';
print: (self red * 255) asInteger;
nextPut: $,;
print: (self green * 255) asInteger;
nextPut: $,;
print: (self blue * 255) asInteger;
nextPut: $,;
nextPutAll: anAlpha asString;
nextPut: $) ]
]
7 changes: 5 additions & 2 deletions src/PrismCodeDisplayer-Core/PrismComponent.class.st
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,9 @@ Class {
'lineCountCache',
'cacheSortedObjectWithIntervals'
],
#classInstVars : [
'development'
],
#category : #'PrismCodeDisplayer-Core-Component'
}

Expand Down Expand Up @@ -164,12 +167,12 @@ PrismComponent >> defineScrollCallbackOn: aPreTag url: url menuCallBack: menuCb
on: [ :intervalRequest |
| interval |
interval := intervalRequest substrings: ':'.
self lastIndexLoad: (interval at:2).
self lastIndexLoad: (interval at: 2).
self requestContext
respond: [ :response |
response
nextPutAll:
(NeoJSONWriter
(STONJSON
toString:
(self
displayComputedSourceCodeOnUrl: url asString
Expand Down
2 changes: 1 addition & 1 deletion src/PrismCodeDisplayer-Demo/PrismDemoRoot.class.st
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ Class {

{ #category : #initialization }
PrismDemoRoot class >> initialize [
WAAdmin applicationDefaults removeParent: WADevelopmentConfiguration instance.
self environment at: #WADevelopmentConfiguration ifPresent: [ :class | WAAdmin applicationDefaults removeParent: class instance ].
(WAAdmin register: self asApplicationAt: 'PrismDemo')
addLibrary: PrismLibrary;
addLibrary: JQDeploymentLibrary
Expand Down
Loading

0 comments on commit 6f298e0

Please sign in to comment.