Comments (10)
this has nothing to do with the angular module.
You can do this with quill-themes.
There you can overwrite the css-classes to build your own themes.
To use a custom theme read this:
http://quilljs.com/docs/themes/
from ng-quill.
I think you can't do what I'm saying with Quill themes as they are css files to customize the way it looks and I'm talking about changing the <option>
tags that are in the <select class="ql-size" ...>
element.
Right now the directive is configured as:
templateUrl: 'ngQuill/template.html'
and down below in the return $templateCache.put('ngQuill/template.html',
it is hardcoded to:
'<select title="{{dict.size}}" class="ql-size" ng-if="shouldShow([\'size\'])">' +
'<option value="10px">{{dict.small}}</option>' +
'<option value="13px" selected="">{{dict.normal}}</option>' +
'<option value="18px">{{dict.large}}</option>' +
'<option value="32px">{{dict.huge}}</option>' +
'</select>' +
I was saying that would be nice to have a parameter to send font-size options as value-label objects. I.E.:
[{
label: 'Paragraph',
value: '14px'
}, {
label: 'Subtitle',
value: '18px'
}, {
label: 'Title',
value: '24px'
}]
Or to be able to configure another template file path and let each user deal with their own complex and exhausting html files ๐
from ng-quill.
sry my fault.
feel free to implement it your self and send me a pull request ;)
from ng-quill.
@KillerCodeMonkey No problem!
I'm working in a PR right now. Maybe is not as good as to merge it as is but I hope in best case scenario it's an approach you can tweak.
I'll send you the PR today or tomorrow.
Thank you very much for the quick feedback!
from ng-quill.
from ng-quill.
i will change your code a little bit --> instead of working with the rootScope i will add a configProvider, that can be extended and clean configured.
why do you added $rootScop.message in the demo.html?
from ng-quill.
added config provider and created a new release
from ng-quill.
Oh no, I just used $rootScope because I needed to test it because otherwise I would have added a new controller to do that. But wasn't supposed to be clean at all.
i will change your code a little bit --> instead of working with the rootScope i will add a configProvider, that can be extended and clean configured.
๐ awesome
from ng-quill.
@matikun86 @KillerCodeMonkey Hey guys, I'm wondering how I can add custom font size dropdown into the toolbar. Is there a demo I can refer to? Thanks!
from ng-quill.
from ng-quill.
Related Issues (20)
- Toolbar at the bottom HOT 2
- Hardcoded quill.js link in snow theme HOT 1
- max-length and min-length attributes does not work properly for non-empty model HOT 1
- read-only flag does not work properly HOT 3
- Quill editor content is not equal to ngModel value after pasting unsupported content into quill HOT 6
- Html Tag Attributs Removed HOT 9
- Version Issue HOT 2
- Font-sizes not working HOT 1
- Locks all the events after one successful redirect. HOT 1
- can not display successfully HOT 2
- rel="noopener noreferrer" on links when text is processed with ng-quill HOT 2
- Set Optional Data via Formly HOT 1
- onEditorCreated not updating HOT 1
- Add BSV as donation address. HOT 1
- Came here to deliver kudos HOT 2
- Global event handler HOT 1
- On-Content-Changed event firing on load HOT 3
- Is there a way to initialize the ng-quill content before it is there in the DOM HOT 1
- Any way to focus quill editor onLoad? HOT 2
- 'ng-quill-toolbar' is not a known element HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. ๐๐๐
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google โค๏ธ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from ng-quill.