1
0
mirror of https://github.com/erusev/parsedown.git synced 2023-08-10 21:13:06 +03:00
Commit Graph

28 Commits

Author SHA1 Message Date
Aidan Woods
71d9263664
Pass State to render stack closure 2021-10-13 18:50:04 +01:00
Aidan Woods
c773305bc1
Add RenderStack
This is a special configurable that can be used to alter the
Renderable[] AST before output.
2021-10-12 00:06:51 +01:00
Aidan Woods
ca16d7573d
Fix psalm errors 2021-10-11 19:23:44 +01:00
Aidan Woods
8764512c23
Add SlugRegister so IDs are not duplicated 2020-05-10 14:32:01 +01:00
Aidan Woods
4e99e29d28
Trim leading and trailing hyphens from slug 2020-05-10 14:32:00 +01:00
Aidan Woods
d8bf07535c
Strip superscripts and divisions from eventual slug
As suggested by @Ayesh

Co-authored-by: Ayesh Karunaratne <ayesh@ayesh.me>
2020-05-10 14:32:00 +01:00
Aidan Woods
e332b4710a
Add HeaderSlug configurable
Adds HeaderSlug configurable, with the option for the slug function
to be customised.

Co-authored-by: netniV <netniv@hotmail.com>
2020-05-10 14:31:55 +01:00
Aidan Woods
c835535176
Implement DefinitionBook as MutableConfigurable
This is a slightly more correct implementation, but perhaps not worth
the headache.
2020-05-10 14:19:05 +01:00
Aidan Woods
2235e36a2c
Use verb imperative to indicate method is non-mutating 2020-01-19 18:06:22 +00:00
Aidan Woods
a2ea704a43
Use list type over int array 2020-01-19 15:23:58 +00:00
Aidan Woods
37f306c3a8
Utilise constant arrays over static vars 2019-07-25 00:45:53 +02:00
Aidan Woods
9eb6a02334
Limit recursion depth by configurable
Fixes https://github.com/erusev/parsedown/issues/681
2019-04-07 17:34:40 +01:00
Aidan Woods
4501a094db
Remove copy-pasto 2019-04-07 16:38:19 +01:00
Aidan Woods
4fb6ac31a5
Improve tests 2019-04-07 16:38:18 +01:00
Aidan Woods
4dee1e9a55
Add convenience instance-based initialisers 2019-04-07 16:38:11 +01:00
Aidan Woods
dbc0efeec0
Require integer-keyed lists so that array_merge result is predictable 2019-04-07 16:38:11 +01:00
Aidan Woods
82d20d8ffe
Markup like CommonMark 2019-04-07 16:38:09 +01:00
Aidan Woods
b89bd0e3c2
Add breaks configurable 2019-04-07 16:38:05 +01:00
Aidan Woods
fce09a702a
Put reused code in a trait so boolean configurables are easy to make 2019-04-07 16:38:05 +01:00
Aidan Woods
8fe93f30ac
Add easy way to remove Components from InlineTyes and BlockTypes 2019-04-07 16:38:05 +01:00
Aidan Woods
57632f38fb
More meaningful method name 2019-04-07 16:38:05 +01:00
Aidan Woods
5e7fb61879
More keyword fixes for pre-PHP7 2019-04-07 16:38:05 +01:00
Aidan Woods
fce4633ff9
Inlines and Blocks as Configurables 2019-04-07 16:38:04 +01:00
Aidan Woods
3d41f270c2
Better name for testing safe mode and strict mode state
Add a nice named constructor
2019-04-07 16:38:03 +01:00
Aidan Woods
351a68a14c
Remove some return type hints that I missed 2019-04-07 16:37:59 +01:00
Aidan Woods
a9aa7e7aae
Test on PHP 5.5 and 5.6
Issue on pre PHP 7 may be to do with method name and not call syntax as
suspected
2019-04-07 16:37:59 +01:00
Aidan Woods
db657952d1
Add DefinitionBook configurable to replace definition data 2019-04-07 16:37:53 +01:00
Aidan Woods
c55dbb0d3f
Add safe mode and strict mode configurables 2019-04-07 16:37:53 +01:00