Comments (2)
This is more of a CSS question than an issue with my module. You can certainly style dropdowns individually by just using CSS that targets the generated HTML from the directive.
For instance, you could target the dropdown pieces by giving specifying another class name, or by targeting based on parent container.
<!-- you can target via .aClass on this dropdown -->
<div class="aClass" dropdown-select="ddSelectOptions" dropdown-model="ddSelectSelected"></div>
<!-- you can target this dropdown via its parent -->
<div id="aParentContainer">
<div dropdown-select="ddSelectOptions" dropdown-model="ddSelectSelected"></div>
</div>
.aClass.wrap-dd-select {
background-color: green;
}
#aParentContainer .wrap-dd-select {
background-color: purple;
}
from angular-dropdowns.
When I do the first approach .aClass .wrap-dd-menu , I get changes in the
button, but the dropdown menu does not change from that set in
angular-dropdowns/css/dropdowns.css for .wrap-dd-menu You set
width:200px; I changed it to width:80px; and for the second button
dropdown on the same page, I want it to be width:100px;
For this second button, I used a different class="btn-post" and my HTML is:
<div id="postBox" class="floatingSection"
ng-controller="postButtonController">
Post Button
In my own external CSS style sheet, I have this CSS, but none of it takes
effect, i.e., background and width do not take effect
.btn-post .wrap-dd-menu{
/* Size and position */
background:#eaaa32; /* apricot tan */
position: relative;
width: 100px; /* original clone 200px; 75px is OK */
margin: 0 auto;
padding: 10px;
}
I've tried several things (including the above CSS in your dropdowns.css),
and it appears to me that the dropdown styling is set only once by this
line in the dropdownMenu directive
$wrap = angular.element("
");As best I can tell, the button styling can be changed, but the dropdown
menu cannot.
On Mon, Jun 30, 2014 at 2:52 PM, James Seppi [email protected]
wrote:
This is more of a CSS question than an issue with my module. You can
certainly style dropdowns individually by just using CSS that targets the
generated HTML from the directive.For instance, you could target the dropdown pieces by giving specifying
another class name, or by targeting based on parent container..aClass.wrap-dd-select {
background-color: green;}
#aParentContainer .wrap-dd-select {
background-color: purple;}—
Reply to this email directly or view it on GitHub
#18 (comment)
.
Mike Laird
12 Arbor Creek Drive, Pittsford, New York 14534
[email protected]
". . . remembering on both sides that civility is not a sign of weakness,
and sincerity is always subject to proof. Let us never negotiate out of
fear, but let us never fear to negotiate." - John F. Kennedy
from angular-dropdowns.
Related Issues (20)
- AngularJS 1.4.x support ? HOT 3
- Scrollable dropdown HOT 1
- conditional dropdownOptions HOT 1
- i18n support HOT 1
- Ability to focus on tab HOT 2
- click also triggers focus action
- Modifying dropdownMenu wrap element HOT 1
- support for npm? HOT 1
- Touch Issues
- Detect change event HOT 1
- Dropdown validation HOT 2
- Support for ng-class attribute HOT 1
- drop down is hang in IE HOT 3
- Clear dropdown HOT 3
- Bower or npm package HOT 1
- Use npmcdn instead of bower
- Css to the selected item HOT 3
- append to body option
- How I use Custom Templates HOT 1
- set icon programmatically 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 angular-dropdowns.