gwomacks / php-debug

Atom Text Editor package for PHP debugging
MIT License
119 stars 31 forks source link

Fix array length, sort context vars, console commands stack, context var list themeability (UPDATED) #220

Open cgalvarez opened 7 years ago

cgalvarez commented 7 years ago

Concerns addressed by this pull request:

Console

Context var list

Editor

Here is a screenshoot showing the improvements:

atom-php-debug-capture

DISCLOSURE: I've made some CSS customizations apart. If some users like it, I could ship them with the PR (like the = and : to separate variables/keys/properties from their values, or the layout of the panels).

cchamplin commented 7 years ago

Over all I really like these adjustments. The only thing I'm not sure about is the sorting of arrays. My concern is that in general PHP sorts array keys internally in the order they were added to the array. If as user expects their arrays to follow PHP internals this might be confusing to see the keys order alpha-numerically. Thoughts?

cgalvarez commented 7 years ago

Hi @cchamplin . I'm currently a little busy, but I'll try to split these features into multiple PRs ASAP.

The sorting of arrays is made only in the variables inspector widget to ease the searching of specific keys. I found it invaluable when searching for keys in $_GLOBALS or $_REQUEST. You can always get the real order by entering the variable in the console if you want.

BTW, the distribution shown in the screenshot and some styles are not included in this PR (I mean the icons and the layout of the widgets and the styles of the stack context, for example). I'm applying them through a customized styles.less inside Atom. Do you want me to make another PR for these styles as well?

StAmourD commented 6 years ago

@cgalvarez These are split into a few PRs. I've tried to use the --author flag when committing hopefully this gives you credit. I'm not sure how well that will work though, feel free to re-split them or pull them into your account and resubmit the PRs.