colinodell

colinodell

Senior Software Engineer at @wayfair. @thephpleague leadership team. Baltimore PHP co-organizer. International conference speaker. PHP 7 Upgrade Guide author.

Member Since 11 years ago

@unleashedtech , Frederick, Maryland

Experience Points
326
follower
Lessons Completed
111
follow
Lessons Completed
809
stars
Best Reply Awards
132
repos

820 contributions in the last year

Pinned
⚡ Highly-extensible PHP Markdown parser which fully supports the CommonMark and GFM specs.
⚡ Convert HTML to Markdown with PHP
⚡ UTF-8 compatible JSON5 parser for PHP
⚡ A simple alarm control panel for Home Assistant's manual_mqtt alarm. Designed to run on a Raspberry Pi using an Adafruit 3.5" PiTFT.
⚡ Which hosts support which PHP versions, and which is default
⚡ Simple command line utility to check the status of an SSL certificate
Activity
Jan
24
6 hours ago
push

colinodell push thephpleague/config

colinodell
colinodell

jekyll build from Action a89b62e9ce89210244ebabe7adcd873435a0f22c

commit sha: 8cda5727594df6a25401bc8927c2b03086abba20

push time in 5 hours ago
push

colinodell push thephpleague/commonmark

colinodell
colinodell

jekyll build from Action 26609f18b3a12e5a08ce621f4782fc0b849d1126

commit sha: 8ed1ce9bc8413b27f0a0467b7caff91498a02211

push time in 6 hours ago
Jan
23
1 day ago
push

colinodell push thephpleague/config

colinodell
colinodell

jekyll build from Action a89b62e9ce89210244ebabe7adcd873435a0f22c

commit sha: e85d929531108ce5c0d39f01c8e57e9cccd95b32

push time in 1 day ago
push

colinodell push thephpleague/commonmark

colinodell
colinodell

jekyll build from Action 26609f18b3a12e5a08ce621f4782fc0b849d1126

commit sha: 9de4cad85d5188426afcd0861e473a71fcf15e2f

push time in 1 day ago
Jan
22
2 days ago
started
started time in 1 day ago
Activity icon
published release v0.1.0
createdAt 1 day ago
push

colinodell push thephpleague/commonmark

colinodell
colinodell

jekyll build from Action 6490a6a4afca165d4c09f3e8c372f89f41580845

commit sha: 7704163a0338027cd5fdcbc9e699efe67d210d91

push time in 1 day ago
Activity icon
issue

colinodell issue comment thephpleague/commonmark

colinodell
colinodell

Table extension: Add (optional?) container element to handle horizontal overflow

Description

I'm using the Tables extension to add tables to markdown. On small screens the tables often extend outside of the viewport, breaking the page layout.

This is because elements with display: table do not respond to width and max-width the same way block elements do. There's no easy CSS way to constrain the table to its container. In the past I've handled it like so:

<div style="overflow-x: auto; max-width: 100%">
  <table><!-- table innards... --> </table>
</div>

It would be nice if there was a way to configure the tables extension to wrap all tables in an element (div?) with a configurable class (e.g. table-container). This would make it easy to use the table extension without breaking responsive layouts.

In the meantime it seems like the only workaround is to extend the Table Renderer with a custom render function. (Which is not the end of the world, by any means, but it would be nice if this was a built-in option.)

I'm currently pretty busy at work, but if this is a feature you're open to I could try to find time to make a PR in the future.

Example

Take the following markdown:

|Heading|Heading|
|--------|--------|
|Content|Content|

It currently outputs something like this:

<table><!-- table innards... --></table>

It would be nice if it output this instead:

<div class="table-container">
  <table><!-- table innards... --></table>
</div>

To prevent making this a breaking change, it would probably be best to make this an optional configuration setting for the tables extension.

Did this project help you today? Did it make you happy in any way?

This project is sooooooo good. I'm working on a project that requires some pretty complex custom markdown parsing, and the extension structure makes this really easy to set up. (I was originally planning to use a lot of regex, but I'm glad I found this project instead 😅 )

Thank you so much for your work on this project! It works great, is a breeze to build off of, and has saved me a ton of time!

colinodell
colinodell

I've added that additional option and released the feature in https://github.com/thephpleague/commonmark/releases/tag/2.2.0! 🎉

push

colinodell push thephpleague/commonmark

colinodell
colinodell

jekyll build from Action c5aadcc15548629787d02b86a7afef03b46271b5

commit sha: 406be0f4be7df6cc5c050503c22f9db31b63a014

push time in 1 day ago
push

colinodell push thephpleague/commonmark

colinodell
colinodell

jekyll build from Action c5aadcc15548629787d02b86a7afef03b46271b5

commit sha: ef519d1c5de4c46dd9a4d59c232aa857c8f1a901

push time in 1 day ago
push

colinodell push thephpleague/commonmark

colinodell
colinodell

jekyll build from Action c5aadcc15548629787d02b86a7afef03b46271b5

commit sha: 15928402a17c7c1254c029db92ffdd91194e12bb

push time in 1 day ago
push

colinodell push thephpleague/commonmark

colinodell
colinodell

jekyll build from Action c5aadcc15548629787d02b86a7afef03b46271b5

commit sha: b359d3272a5bc84c919d85cf2a495f652a19d941

push time in 1 day ago
push

colinodell push thephpleague/commonmark

colinodell
colinodell

jekyll build from Action e33f442c292d471cd485cf0c04200792d877bb49

commit sha: 908e78799caa5a2fac8ab0c868947e628c454084

push time in 1 day ago
Activity icon
published release 2.2.0

colinodell in thephpleague/commonmark create published release 2.2.0

createdAt 1 day ago
Activity icon
created branch
createdAt 1 day ago
Activity icon
created tag
createdAt 1 day ago
push

colinodell push thephpleague/commonmark

colinodell
colinodell

Bump ridedott/merge-me-action from 2.9.93 to 2.9.94

colinodell
colinodell

Bump ridedott/merge-me-action from 2.9.94 to 2.9.96

colinodell
colinodell

Bump ridedott/merge-me-action from 2.9.96 to 2.9.98

colinodell
colinodell

Merge remote-tracking branch 'origin/2.1'

colinodell
colinodell

commit sha: e33f442c292d471cd485cf0c04200792d877bb49

push time in 1 day ago
push

colinodell push thephpleague/commonmark

colinodell
colinodell

jekyll build from Action 00c1b72a7fb0fe1bdef67bcfe37285fbadf1ebd3

commit sha: abdd0fec43f38504a7790040d10a317c0f408084

push time in 1 day ago
Activity icon
issue

colinodell issue thephpleague/commonmark

colinodell
colinodell

Table extension: Add (optional?) container element to handle horizontal overflow

Description

I'm using the Tables extension to add tables to markdown. On small screens the tables often extend outside of the viewport, breaking the page layout.

This is because elements with display: table do not respond to width and max-width the same way block elements do. There's no easy CSS way to constrain the table to its container. In the past I've handled it like so:

<div style="overflow-x: auto; max-width: 100%">
  <table><!-- table innards... --> </table>
</div>

It would be nice if there was a way to configure the tables extension to wrap all tables in an element (div?) with a configurable class (e.g. table-container). This would make it easy to use the table extension without breaking responsive layouts.

In the meantime it seems like the only workaround is to extend the Table Renderer with a custom render function. (Which is not the end of the world, by any means, but it would be nice if this was a built-in option.)

I'm currently pretty busy at work, but if this is a feature you're open to I could try to find time to make a PR in the future.

Example

Take the following markdown:

|Heading|Heading|
|--------|--------|
|Content|Content|

It currently outputs something like this:

<table><!-- table innards... --></table>

It would be nice if it output this instead:

<div class="table-container">
  <table><!-- table innards... --></table>
</div>

To prevent making this a breaking change, it would probably be best to make this an optional configuration setting for the tables extension.

Did this project help you today? Did it make you happy in any way?

This project is sooooooo good. I'm working on a project that requires some pretty complex custom markdown parsing, and the extension structure makes this really easy to set up. (I was originally planning to use a lot of regex, but I'm glad I found this project instead 😅 )

Thank you so much for your work on this project! It works great, is a breeze to build off of, and has saved me a ton of time!

Activity icon
delete

colinodell in thephpleague/commonmark delete branch decorate-table-output

deleted time in 1 day ago
push

colinodell push thephpleague/commonmark

colinodell
colinodell

Allow any Stringable to be used as HtmlElement contents

colinodell
colinodell

Add config for optionally wrapping tables within a container

colinodell
colinodell

Merge pull request #787 from thephpleague/decorate-table-output

Decorate table output

commit sha: 00c1b72a7fb0fe1bdef67bcfe37285fbadf1ebd3

push time in 1 day ago
Previous