jeremy@jermolene.com
0e4e037bb7
Changed transclude widget in binary parser to ubertransclude
2022-04-26 13:05:31 +01:00
jeremy@jermolene.com
cd0617f033
Use the ubertransclude widget for the wikitext transclusion syntax
2022-04-26 12:45:05 +01:00
Jeremy Ruston
5378b45c40
Allow newlines within filtered transclusions ( #6421 )
...
* Allow newlines within filtered transclusions
* Docs
2022-02-21 15:28:21 +00:00
Jeremy Ruston
23b4e03cd5
Extend HTML tag parser to maintain an ordered array of attribute names ( #6132 )
...
* Extend HTML tag parser to maintain an ordered array of attribute names
* Add some tests for repeated attributes
* Record entire attribute in orderedAttributes array so that we can work with duplicated attributes
2021-10-27 11:35:12 +01:00
jeremy@jermolene.com
5f57bf81cd
Merge branch 'pr/4977'
2021-10-27 11:18:57 +01:00
Saq Imtiaz
041c3e817c
Support for macro params in filter operands ( #5836 )
...
* Exploratory pass at adding support for macro params in filter operands
* whitspace correction
* rename varInfo to varTree for disambiguation
* Refactored parseMacroInvocation to be re-usable, performance improvements for variables with no params and tests
* Revised regular expression and removed spurious white space changes
* Revised regular expression and removed spurious white space changes
* More whitespace cleanup and added more tests for edge cases
* Added test for macro params with square brackets
2021-06-29 22:21:39 +01:00
Mario Pietsch
9c0d6a46cc
Add "commentpragma" html style rule ( #5726 )
...
* html-comment, that can be used in the pragma area
* add commentpragma test
* fix typo
* fix typo and change comments ab bit
* combine html-comment and pragma-comment and add some docs, how to use it
* Make docs simpler by removing caching info
* change h2 wording
2021-06-14 17:39:56 +01:00
Joe Bordes
82ec63e711
style(App) eliminate whitespace at the end of code lines ( #5735 )
2021-05-30 19:20:17 +01:00
Miha Lunar
9b247f6d63
Removed fallback range logic
2021-05-29 20:30:04 +02:00
Cameron Fischer
61714cbda3
Fixed super minor issue with import pragma ( #5521 )
2021-05-23 17:39:06 +01:00
Miha Lunar
62fdaa633a
Fixed fallback range logic + added ranges to tests
2021-04-25 16:03:35 +02:00
Miha Lunar
79f5e6b498
Merge remote-tracking branch 'origin/master' into parser-ranges
2021-04-25 13:17:44 +02:00
Miha Lunar
23bd7e7817
Replaced restructuring and added fallback comment
2021-04-25 13:12:45 +02:00
jeremy@jermolene.com
89546b3357
Add a hidden setting to control HTML sandboxing
2021-04-11 10:10:16 +01:00
jeremy@jermolene.com
9f9ce6595b
Make it easier to subclass the wikitext parser with a custom rule set
...
We can now pass arrays of rule classes to the parser constructor, overriding the rules that would normally be used by the parser.
This allows us to create custom variants of the wikitext parser with their own content type.
It could also provide a basis for a new Markdown parser based on our existing wikitext parser but with new rules.
2021-02-03 15:13:56 +00:00
Cameron Fischer
4c7dcb83d1
Fix for #3306 , inline/block widget glitch ( #5452 )
...
* Fix for #3306 , inline/block widget glitch
* Just realized we don't need to set lastIndex anymore
* Forgot that parseBlocks doesn't use options
2021-01-29 14:57:30 +00:00
Cameron Fischer
45355a7fcf
Wikirules now use better macrocall parser ( #5451 )
...
* wikirules now use better macrocall parser
Before, wikirules would use a deficient macrocall parser which couldn't
handle certain types of arguments. Now it uses the same one that the
widget parser uses. Less code!
* style changes and removing weird switch statement
That switch statement made more sense in an earlier iteration.
* comment improvements
* oops, wikirule macrocalls could do ONE thing better
* '=' wasn't allowed for widget macros, but why?
Now they're allowed for both widget macros and macrocall macros.
2021-01-29 13:26:31 +00:00
jeremy@jermolene.com
ca95f1069f
Fixed comment parsers to match end marker correctly
...
Fixes #5396
2021-01-13 11:48:42 +00:00
jeremy@jermolene.com
d25e540dd2
Add support for image/vnd.microsoft.icon content type
...
Fixes #5357
2021-01-03 10:04:52 +00:00
jeremy@jermolene.com
d181b96518
Wikitext parser: Refactor a poorly written utility function
2020-11-18 12:05:06 +00:00
Miha Lunar
1b226c7556
Fixed coding standard nits
2020-11-06 19:56:20 +01:00
Miha Lunar
2bd9cc45fa
Added more start/end parser ranges
2020-11-04 21:02:17 +01:00
Nils-Hero Lindemann
322c37d693
Let chained >
blockquotes generate valid HTML ( #4332 )
...
* Replace "p" with "div" in itemTag
'>> text' will now be valid html.
* Make the new div's behave like p's
2020-04-07 20:39:13 +01:00
Lee Sheng Long
96eca32b11
Add download button/link to binary tiddler warning banners in view and edit mode ( #4423 )
2020-01-31 09:13:28 +00:00
Stefan Krüger
1ed884cef4
Add support for file type webm & ogg theora ( #4404 )
2020-01-04 11:27:13 +00:00
donmor
588af44d4c
Scale embedded videos and audios to fit their container ( #3943 )
...
* Update videoparser.js
* Update audioparser.js
* Update videoparser.js
* Update audioparser.js
2019-10-19 11:44:18 +01:00
Nils-Hero Lindemann
1c5b3e3d8d
Remove duplicate code from transcludeblock parser ( #4221 )
2019-08-30 17:20:16 +01:00
Jermolene
fe85845c3c
Add new "\import" pragma
2018-09-28 16:01:32 +01:00
Jermolene
09112ed455
Add support for webp, heic, and heif image formats
...
https://en.wikipedia.org/wiki/WebP
https://en.wikipedia.org/wiki/High_Efficiency_Image_File_Format
2018-08-21 11:46:46 +01:00
Jermolene
35cbb127a3
Restrict variable substitutions to macros defined with the define pragma
...
Fixes #3333
2018-06-15 08:31:02 +01:00
Jermolene
6b14969cf6
Display a warning for binary tiddlers in view mode
...
The base64 data is currently parsed as wikitext, which is slow and unhelpful
We already display the same warning for binary tiddlers in edit mode.
2018-05-18 17:53:07 +01:00
Matt Lauber
bbccb60c0b
Code Cleanup ( #3178 )
...
Noticed an unused variable in the image parser, from before a old refactor.
2018-03-19 15:46:07 +00:00
Jermolene
ff6aa0570f
Check for dollar sign within HTML element name
...
Fixes #3091
2018-01-16 22:13:40 +00:00
Jermolene
29364cbd08
Change http://*.tiddlywiki.com/ * to https://
2017-11-11 11:56:20 +00:00
Jermolene
d966583854
Add new "\whitespace" pragma
...
This will allow us to simplify some of the more unreadable core
wikitext tiddlers…
2017-07-12 16:46:13 +01:00
Jermolene
0383b98555
Add support for other movie content types
2016-12-23 08:34:07 +00:00
Jermolene
f143164cbe
Correct the name of the video parser
2016-12-22 22:07:28 +00:00
Jermolene
74def9e080
Separate the PDF parser from the image parser
...
It was a bit of a hack, and made it harder to customise PDF presentation
2016-12-15 17:13:32 +00:00
Jermolene
7108e0d861
Add support for filtered attributes to HTML elements and widgets
...
Fixes #2624
2016-10-21 11:27:07 +01:00
Jermolene
accd4a1b65
Fix regexp performance problem introduced in c7b31b0242
...
This fixes a problem introduced in
c7b31b0242
.
The changes by @tobibeer inadvertently made the regular expression
evaluation significantly more expensive because of lookahead. The is
less elegant but reverts the performance problem.
2016-10-17 19:08:01 +01:00
Jermolene
da298f037d
Remove extraneous console.log()
...
Fixing f97c1226aa
2016-10-12 15:50:43 +01:00
Jermolene
f97c1226aa
Prevent HTML parser from mis-recognising email addresses
...
Email addresses such as `<jeremy@example.com>` were being erroneously
parsed as HTML tags.
Fixes #2604
2016-10-12 13:17:53 +01:00
Tobias Beer
b9299309cc
Fixes #2076 single line macros shouldn't need terminating line break
2016-10-08 13:44:30 +01:00
Tobias Beer
c7b31b0242
allows textPrimitives.anyLetter in syslink ( #2596 )
...
* allows textPrimitives.anyLetter in syslink
now only supports anyletter as per request by @jermolene
2016-10-08 11:51:07 +01:00
Jermolene
782553eb62
Remove tilde from characters not allowed in external URLs
2016-07-13 14:06:47 +01:00
Jermolene
dca9e008ce
Remove single quote from illegal characters in URLs
...
Fixes #2493
2016-07-12 17:22:20 +01:00
Jermolene
682b1e7027
Fix sandbox attribute for html parser generated iframes
...
See
https://developer.mozilla.org/en/docs/Web/HTML/Element/iframe#attr-sandb
ox
2016-05-17 15:45:10 -06:00
Jermolene
3a3754aebb
Add rel="noopener noreferrer" to external links
...
Background:
https://medium.com/@jitbit/target-blank-the-most-underestimated-vulnerab
ility-ever-96e328301f4c#.hduwdbjlb
2016-05-05 11:49:40 +01:00
Jermolene
df3e39d97a
Update wikiparser file comment
2016-02-15 11:33:47 +00:00
Jermolene
99df9f46f7
Add support for tiddlers containing mp4 videos
2015-10-01 12:13:38 +01:00