Closed jibsaramnim closed 3 years ago
This pull request is being automatically deployed with Vercel (learn more).
To see the status of your deployment, click below or on the icon next to each commit.
🔍 Inspect: https://vercel.com/justineo/vue-clamp/FJMQXvkxKkj1DXL8AgZaJVaXhgWr
✅ Preview: https://vue-clamp-git-fork-jibsaramnim-master-justineo.vercel.app
@Justineo thank you kindly for taking a look! I have applied the changes you have suggested, including removing the compiled demo files and adding that folder to .gitignore
. Please let me know if there is anything else you'd like me to do, I'm more than happy to help! :)
Thank you!
@Justineo just a small note; it might be useful to update the Github repo demo URL, as it's still pointing to https://justineo.github.io/vue-clamp/demo/ which isn't working anymore now.
@jibsaramnim Oops I forgot about that. Fixed now, thank you!
This PR adds a new property that lets you specify where you would like to have the ellipsis be shown. By default this appears at the
end
, but now you can also choosestart
andmiddle
. The latter splits the text in half*, placing the ellipsis right in the middle.I must apologize in advance as I do not speak Chinese, so I was not able to provide translations for the added content on the demo page. It would be great if you could take a look at this and, if it looks alright to you too, merge this. I have tried to make sure I followed your existing formatting, but please let me know if I made any mistakes, or missed any details.
Thank you!
* Using
Math.floor
on the left-hand side, andMath.ceil
on the right-hand side, to support uneven string lengths too.