|
4f78f1d6
|
2019-03-24T12:42:17
|
|
Name in composer.json set to lowercase (#1824)
This conforms to Packagist standards so we can properly submit prismjs to Packagist
so Composer users can pull in the project.
|
|
a91be7b2
|
2019-03-22T18:16:03
|
|
Apache config: Minor improvements + new keyword (#1823)
This adds the `SSLSessionTickets` word to the list of inline directives and compresses current word lists.
|
|
30779976
|
2019-03-20T22:10:17
|
|
Added support for CMake language (#1820)
This adds support for the [CMake](https://cmake.org/) language.
|
|
bc649dfa
|
2019-03-14T18:54:40
|
|
npm: Fixed `test` script (#1809)
This solves the problem that is wasn't possible to pass arguments to `tests/run.js`.
|
|
f2d8e1c7
|
2019-03-14T15:03:11
|
|
JS: Keyword fix (#1808)
This fixes false positives with properties which have the same name as keywords.
|
|
dedb475f
|
2019-03-14T13:49:47
|
|
Added issue templates (#1805)
This adds issue templates for the prism project after #1802.
|
|
11d0f75e
|
2019-03-14T13:17:45
|
|
Applied Array.isArray (#1804)
This replaces all occurrences of `Prism.util.type(variable) {!==, ===} 'Array'` with an equivalent `Array.isArray` expression.
|
|
a944c418
|
2019-03-11T17:55:56
|
|
Add unit tests to the Keep Markup plugin (#1646)
Uses JSDOM to simulate the DOM in node.
|
|
439ea1ee
|
2019-03-11T00:32:45
|
|
Added scripts directory (#1781)
This adds a new `scripts` directory for all scripts used exclusively by the prismjs.com website.
|
|
3100fa31
|
2019-03-11T00:21:16
|
|
More persistent test page (#1529)
The test page will now remember the language and code last tested.
|
|
bc53e093
|
2019-03-11T00:20:18
|
|
More variables for better code compression (#1489)
This introduces more variables for better code compression in a few languages.
|
|
70a40414
|
2019-03-10T22:15:10
|
|
CSS extras: Highlighting for pseudo class arguments (#1650)
This adds highlighting for pseudo class arguments, selector punctuation, and n-th expressions.
|
|
18f2921d
|
2019-03-10T21:40:02
|
|
Docs: Added missing parameter (#1774)
This adds a missing parameter to the `Prism.highlight` documentation.
|
|
832a9643
|
2019-03-10T21:30:58
|
|
Refactored tests (#1795)
This refactors all test related JS files.
|
|
729cb28b
|
2019-03-10T21:18:27
|
|
Test page: Show tokens option (#1757)
This adds a new option to the test page to show a visual representation of the nested structure of the tokens of highlighted code Prism returns.
|
|
ea769e0b
|
2019-03-10T18:58:45
|
|
Some encouragement for visitors of PrismJS.com to request new languages (#1760)
This adds a direct link to our Github issue page, encouraging visitors to make a new issue to request a new language.
|
|
14be7489
|
2019-03-10T18:56:59
|
|
Line numbers: Added inheritance for the `line-numbers` class (#1799)
This adds inheritance for the `line-numbers` class for the Line numbers plugin similar to the inheritance of `language-xxxx` classes.
|
|
9ea6d600
|
2019-03-10T18:55:23
|
|
Tests: Pretty-printed token stream (#1801)
This adds support for pretty-printed token streams in the output of error messages.
|
|
f2467488
|
2019-03-10T18:53:08
|
|
Django/Jinja2 improvements (#1800)
This completely rewrites the Django language definition. It's now based on markup-templating.
|
|
af67c32e
|
2019-03-10T18:44:30
|
|
Markup `addInline` improvements (#1798)
This makes some minor improvements to the new `addInline` function of markup.
|
|
b2298b12
|
2019-03-10T15:45:40
|
|
Added GraphQL improvements and tests (#1788)
This makes some improvements to GraphQL and expands the existing tests.
|
|
3e00bb9c
|
2019-03-07T15:22:30
|
|
Rebuilt Prism (#1794)
This is a rebuilt of Prism to update minified files.
|
|
5dd8f916
|
2019-03-06T18:09:45
|
|
JSONP highlight: Fixed minified adapter names (#1793)
This fixes that the Uglify minified functions names made the pre-defined adapters un-removable.
|
|
9d908d5a
|
2019-03-06T18:04:34
|
|
npm: Updated all dependencies (#1742)
This updates all npm dependencies.
|
|
8ca3d65b
|
2019-03-06T13:53:33
|
|
Markdown: The 'md' alias is now recognized by hooks (#1771)
The hooks markdown adds itself will now recognize the `md` alias.
|
|
86dd3e42
|
2019-03-06T13:49:05
|
|
Fixed patterns which can match the empty string (#1775)
This changes patterns which match the empty string to always match at least one character.
|
|
c9762c6f
|
2019-03-06T13:47:25
|
|
Better class name detection for plugins (#1772)
This improves the class name regex of a few plugins to avoid false positives.
|
|
a2d445d0
|
2019-03-06T13:22:08
|
|
CSS: Selectors can contain any string (#1638)
This fixes that certain attribute value strings break the selector pattern.
|
|
878ef295
|
2019-03-05T22:26:50
|
|
Themes: Normalized the font-size of pre and code (#1791)
Normalized the font-size of pre and code in all themes. This fixes a Coy line drift issue.
|
|
c37c90df
|
2019-03-05T22:17:36
|
|
Added EJS (#1769)
This adds the EJS (Embedded JavaScript templates) language to Prism.
|
|
c9a32674
|
2019-03-05T22:06:33
|
|
Fixed dependencies of Pug and Pure (#1759)
This removes dependencies of Pug and Pure to languages which do not exist (yet).
|
|
c805f859
|
2019-03-05T16:56:13
|
|
Ruby/ERB: Fixed block comments (#1768)
This fixes block comments in Ruby and ERB.
|
|
571704cb
|
2019-03-04T23:38:57
|
|
Regex language (#1682)
This adds a Regex language that adds itself to a few languages which have regex literals.
|
|
57127701
|
2019-03-04T23:12:46
|
|
Markup: Added support for CSS and JS inside of CDATAs (#1660)
This adds support for CSS/JS inside of (any number of) CDATAs.
|
|
16f2ad06
|
2019-03-04T22:59:24
|
|
Added T4 Text Templates (#1699)
This adds T4 Text Templates in both the C# and VB language variants.
|
|
245b59d4
|
2019-03-04T22:17:23
|
|
CSS: Highlight attribute selector (#1671)
This adds highlighting for CSS attributes selectors in CSS Extras
|
|
f8c8add2
|
2019-03-03T14:10:47
|
|
Fixed operator-like functions in Scheme (#1467)
This fixes operator-like functions in Scheme.
|
|
b62e282b
|
2019-03-03T00:01:55
|
|
Markup-templating improvements (#1653)
This makes minor improvements to markup-templating.
|
|
6c9fe257
|
2019-03-02T17:43:23
|
|
gulp: Refactoring (#1780)
Refactored gulpfile.js
|
|
bac09f0a
|
2019-03-02T17:27:19
|
|
Made prism-core a little more editor friendly (#1776)
This makes the structure of prism-core easier to understand for editors.
|
|
3b396ef5
|
2019-03-02T04:09:06
|
|
Added new SAS keywords (#1784)
This adds the SAS keywords libname, set, output, and options to the language definition.
|
|
06627f6a
|
2019-03-01T13:41:02
|
|
Update gulp to version 4.0.0 (#1779)
|
|
b06f532f
|
2019-03-01T01:19:29
|
|
Core: Avoid redeclaring variables in util.clone (#1778)
This changes util.clone to be more readable and to avoid redeclaring the `clone` and `id` variables.
|
|
289ddd9b
|
2019-02-28T21:56:01
|
|
PHP: Fixed closing tag issue (#1652)
This fixes that PHP's closing tag (`?>`) was detected inside strings and comments.
|
|
152a68ef
|
2019-02-28T21:36:57
|
|
Improved languages.DFS and util.clone (#1506)
Minor improvements for the two functions.
|
|
493d19ef
|
2019-02-28T21:01:31
|
|
Added doc comment highlighting (#1541)
This adds support for JavaDoc, JSDoc, TSDoc, and PHPDoc.
|
|
bb628606
|
2019-02-28T20:19:45
|
|
Added JS Extras (#1743)
This adds JS Extras, a few additional features for the JS language.
|
|
3560c643
|
2019-02-28T20:12:11
|
|
JS: Fixed variables named "async" (#1738)
Fixes variables names "async" in JS.
|
|
c3862a24
|
2019-02-28T19:55:24
|
|
Fix for markup attributes (#1752)
This fixes some issues related to markup (XML/HTML) attributes. See the PR for more detail.
|
|
5fd7577a
|
2019-02-28T19:52:06
|
|
Smalltalk: Allowed empty strings and comments (#1747)
This fixes that empty strings and comments were not recognized in Smalltalk.
|
|
7bcec584
|
2019-02-28T19:41:00
|
|
Improved JS constant pattern (#1737)
This changes the JS constant pattern so that all WebGL constants (like `FLOAT_MAT2x4`) are matched.
|
|
8378ac83
|
2019-02-28T19:33:50
|
|
Improved JS function pattern (#1736)
Allows for spaces around the punctuations of function invocation via `apply`, `bind`, or `call`.
|
|
64dc049d
|
2019-02-28T19:28:22
|
|
Added JSON5 language (#1744)
This adds the JSON5 language to Prism.
|
|
13e1c97d
|
2019-02-28T19:23:25
|
|
Added EBNF language (#1756)
This adds the EBNF language.
|
|
1df96c55
|
2019-02-28T19:18:05
|
|
Added BNF and RBNF languages (#1754)
This adds the BNF and RBNF languages.
|
|
6d98f0e7
|
2019-02-28T19:10:37
|
|
Added ANBF language (#1753)
This adds a new language: ANBF (Augmented Backus–Naur form).
|
|
ae4842db
|
2019-02-27T14:54:06
|
|
Fixed JSON/JSONP examples (#1765)
This corrects my previous mistake where I forgot to adjust the example of JSON after changing the implementation of JSONP.
|
|
b5041cf9
|
2019-02-26T05:41:01
|
|
Fix JSONP support (#1745)
This PR fixes that JSON did not support [JSONP](https://en.wikipedia.org/wiki/JSONP) callback functions.
I also added a JSON example page.
|
|
5bd182c0
|
2019-02-26T04:43:27
|
|
Fix Lisp exponential string pattern (#1763)
This PR fixes #1762 by fixing the `string` pattern which sometimes fails in exponential time.
|
|
ce9616a0
|
2019-02-20T16:12:00
|
|
Fix typo (#1755)
|
|
bfbea4d6
|
2019-02-15T16:51:54
|
|
Fix `function-variable` in JS (#1739)
|
|
671f4ca0
|
2019-02-15T16:05:43
|
|
Improve gulp error messages with pump (#1741)
|
|
d9fa29a8
|
2019-02-15T16:03:59
|
|
Make `undefined` a keyword in JS (#1740)
|
|
bd0378f0
|
2019-02-14T13:23:49
|
|
Add `keyword` alias for SCSS' `null` (#1735)
Add the `keyword` alias to the `null` pattern for SCSS.
This was the last `null` pattern without any aliases (#1727).
|
|
fccfb98d
|
2019-02-14T01:25:25
|
|
Added `pnpm` function to Bash (#1734)
This adds `pnpm` to the list of supported functions in Bash.
|
|
eee06649
|
2019-02-14T01:18:46
|
|
Added `keyword` alias to JSON's `null` (#1733)
This adds the `keyword` alias to the `null` pattern in JSON.
|
|
3a32cb75
|
2019-02-13T22:33:38
|
|
Added `yarn add` to bash functions (#1731)
Adds `yarn add` to bash functions.
|
|
baf6bb0c
|
2019-02-13T20:31:50
|
|
Add support for # comments to INI language (#1730)
This PR resolved #1729.
Disclaimer: # comments are only supported by [some implementation](https://en.wikipedia.org/wiki/INI_file).
|
|
4362e42c
|
2019-02-12T23:30:14
|
|
Support JSX/TSX class-name with dot (#1725)
Adds class-name highlighting for JSX/TSX tag names containing dots.
|
|
5311ca32
|
2019-02-12T20:49:39
|
|
Fixed Toolbar plugin example (#1726)
There was a function parameter missing in one of the Toolbar plugin examples.
|
|
57a92035
|
2019-02-12T20:43:31
|
|
Improved JavaScript parameter recognization (#1722)
- The first letter of a parameter can now be upper case.
- Fixes too greedy regex by introducing recursive expressions.
|
|
8cf20d49
|
2019-02-11T20:35:25
|
|
Fix Autolinker url-decoding all tokens (#1723)
This PR fixes #1721.
The problem was that the url-decoding introduced in #1173 was applied to all tokens.
|
|
00f4f04f
|
2019-02-07T23:20:34
|
|
Line Numbers plugin instructions clarifications (#1719)
This fixes typos and makes clarifies some instructions of the Line Numbers plugin.
|
|
217a6ea4
|
2019-01-24T15:41:32
|
|
Inline ALL regexes (#1716)
This fixes that only the first regex of the form `/regex/.source` was inlined.
(I forgot the `g` flag...)
|
|
bc49c361
|
2019-01-24T12:51:18
|
|
Removed useless `insertBefore` call in Smarty (#1677)
Removes a call to `insertBefore` which has no effect in Smarty.
|
|
1090b253
|
2019-01-23T04:45:07
|
|
Show invisibles inside tokens (#1610)
This PR fixes #1608.
The patterns for invisible characters (ICs) are now also recursively added to the `inside` of every pattern.
I also had to change the color of ICs because in #1607 I changed the color to `inherit` which causes the ICs to have different colors depending on which token they are inside of.
So, to make everything consistent, I changed the color to grey (`rgb(128, 128, 128)`) and made it half transparent so it would blend in. Looks really similar to #1607.
---
Most of the code is just traversing the language definition, handling the different kinds of tokens (simple regex, array, pattern object), and trying not to fall because of the added tokens for ICs and the `rest` property.
|
|
e894fc89
|
2019-01-23T03:05:58
|
|
Inline regex source with gulp (#1537)
Let gulp inline the source of inline regular expressions without flags in minified files.
This means that gulp will replace `/regex/.source` with `'regex'`.
## Motivation
Most IDEs support syntax highlighting and checking of JS inline regular expressions.
This makes them easier to work with and less error-prone than having a string hold the expression. Inline regexes are also usually shorter than their string counterparts because
you don't have to escape backslashes. There are also some linters (e.g. ESLint) for JS
regular expression which (of course) won't work on strings.
This lets you enjoy the advantages of inline regexes without worrying about the additional
overhead of compiling another regular expression on the client side.
|
|
0030a4ef
|
2019-01-23T03:03:04
|
|
Decouple XML from Markup (#1603)
Decouple the XML language from the Markup language so that
changes to `markup` do not affect `xml`. The `style` and `script`
tags added by CSS and JS modify `markup` but not `xml`.
Resolves #1597.
---
We can't test this because the XML language is not in its own file.
|
|
2ce0666d
|
2019-01-23T02:54:47
|
|
Remove parentheses from download page (#1627)
Remove the parentheses around the file sizes for a cleaner look.
|
|
393ab164
|
2019-01-22T13:36:32
|
|
Call `insert-before` hook properly (#1709)
Fixes #1706 (also includes a demo).
The problem was that the `insert-before` hook was not called if `grammar` is undefined.
This also fixes that `callback` was not called in that case and that `env` of the `complete` hook did not have a `highlightedCode` property.
All other hooks are unchanged. The `insert-before` hook is only used by the Command line plugin, so there should be no other side effects.
|
|
6ec71e0b
|
2019-01-22T13:27:53
|
|
Change tested NodeJS versions (#1651)
Remove Node 4 & 9 because both are EOL'd. Node 10 + current were added.
|
|
4c66d72c
|
2019-01-22T11:55:33
|
|
Show Language plugin alias support and improvements (#1683)
Adds support for aliases and optimizes the name guessing.
|
|
fbf0b094
|
2019-01-22T02:20:17
|
|
Remove the Prism.tokenize language parameter (#1654)
The `language` parameter of `tokenize` was unused and the only one calling `tokenize` with a value for the said parameter is Markup-templating (removed in #1653).
It's not [documented](https://prismjs.com/extending.html#api) either.
|
|
cd058a91
|
2019-01-22T01:19:27
|
|
Fix typos & other issues in JSONP docs (#1672)
This PR fixes some typos, indentation mistakes, and corrects the language of some `code` elements.
|
|
28489698
|
2019-01-22T01:17:50
|
|
Cleanup JSONP highlight code (#1674)
Document, refactor and format the JSONP Highlighting plugin.
|
|
dbd3555e
|
2019-01-22T00:53:23
|
|
Fix downloads page fetching from GitHub(#1684)
This resolves #1624.
Fixes the missing examples for newly added language in the [example page](https://prismjs.com/examples.html).
|
|
7eccea5c
|
2019-01-22T00:49:40
|
|
Improve C language (#1697)
This PR adds support for [hexadecimal floating-point literals](http://www.cplusplus.com/doc/tutorial/structures/), and [`enum`](https://www.geeksforgeeks.org/enumeration-enum-c/) and [`struct`](https://www.tutorialspoint.com/cprogramming/c_structures.htm) class names.
|
|
e2d3bc7e
|
2019-01-22T00:39:55
|
|
Remove dead tutorial (#1702)
This PR removes the [dead allblogtools.com tutorial][1].
[1]: http://www.allblogtools.com/tricks-and-hacks/beautify-source-codes-in-your-posts-with-prism-syntax-highlighter-for-blogger/
|
|
66f05ab0
|
2019-01-17T18:42:22
|
|
Deleted prism-hdl.min.js (#1712)
This removes the extra prism-hdl.min.js.
|
|
44aeffb9
|
2019-01-17T17:52:02
|
|
Improved field highlighting for GraphQL (#1711)
Adds highlighting for GraphQL fields with arguments.
|
|
b94b56c1
|
2019-01-15T15:54:35
|
|
Added the Nand2Tetris HDL language (#1710)
This adds support for the [Nand2Tetris](https://www.nand2tetris.org/) HDL language.
|
|
b1f8a65d
|
2019-01-15T12:43:43
|
|
Fixed CHANGELOG.md formatting (#1707)
This fixes some formatting issues in the changelog.
|
|
66d2104a
|
2019-01-13T22:47:58
|
|
Fixed CHANGELOG.md (#1704)
Fixes that swapped commit URLs of ABAP and Erlang for release 1.8.4 (2017-11-05).
|
|
ff9ccbe5
|
2019-01-12T12:56:49
|
|
Added new third-party tutorial for using Prism in Gutenberg (#1701)
This adds a new third-party tutorial to the start page.
|
|
439e3bd7
|
2019-01-11T00:54:01
|
|
Made false, true, and null constants in PHP (#1694)
- This adds the `constant` alias to `false` and `true`.
- `null` is no longer `keyword` but a `constant`.
|
|
7def8f5c
|
2019-01-03T23:52:27
|
|
Added N1QL language support (#1620)
Adds support for[N1QL](https://www.couchbase.com/products/n1ql) for Couchbase.
|
|
efdd96c3
|
2019-01-03T19:28:49
|
|
Updated website table of contents styles (#1681)
The TOC will now be located at the bottom left and be more friendly to smaller screens.
|
|
55fb0f8e
|
2019-01-03T17:22:02
|
|
Update PHP keywords (#1690)
This removes PHP 4 specific keywords and adds new PHP keywords.
Keywords previously classified as functions are now classified as keywords.
|
|
f1026b4b
|
2019-01-03T01:41:36
|
|
Improve recognition of constants in PHP (#1688)
The pattern for PHP constants now have to be a valid identifier and recognizes single-letter names.
|
|
88434f7a
|
2019-01-01T15:52:38
|
|
Added `adoc` alias for AsciiDoc (#1685)
This adds the `adoc` alias for the AsciiDoc language.
|