Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add a [Link] button to the "Try CoffeeScript" interface #1711

Merged
merged 3 commits into from
Sep 21, 2011
Merged

Add a [Link] button to the "Try CoffeeScript" interface #1711

merged 3 commits into from
Sep 21, 2011

Conversation

banksJeremy
Copy link

(Replacing #1628.) This adds a button to the "Try CoffeeScript" interface which is a permalink to the current source code. Here's an example on my fork.

@@ -84,6 +84,7 @@
</div>
<div id="repl_results_wrap"><pre id="repl_results"></pre></div>
<div class="minibutton dark run" title="Ctrl-Enter">Run</div>
<a class="minibutton permalink" id="repl_permalink" style="display: block; top: 38px;" href="#src:">Link</a>
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't like the inline style, and the href value appears unnecessary.

@banksJeremy
Copy link
Author

What is the correct way to make changes? Do I just add commits to this, or do I start a new request so as not to clutter the log?

@michaelficarra
Copy link
Collaborator

I'd like to see the src value in the fragment (referenced in 3 different places) pulled out and assigned to a descriptive variable. Also, something other than src may be more appropriate. Maybe try_cs_permalink? I know, it's a little long...

@michaelficarra
Copy link
Collaborator

Just push extra commits. They'll show up here between the comments.

@banksJeremy
Copy link
Author

I still have the inline styles on the button, I'm not sure of the cleanest place to move them.

@michaelficarra
Copy link
Collaborator

I'm guessing you would put the style in a selector in /documentation/css/docs.css somewhere around the 260s.

@jashkenas jashkenas merged commit de0122d into jashkenas:master Sep 21, 2011
@jashkenas
Copy link
Owner

Thanks -- this is great. Merged with some minor style (camelCase) tweaks.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants