mirror of
https://github.com/flarum/framework.git
synced 2025-02-21 03:59:39 +08:00
Stop propagation when clicking on tag child
This commit is contained in:
commit
670218d267
@ -45,7 +45,10 @@ export default class TagsPage extends Component {
|
||||
? (
|
||||
<div className="TagTile-children">
|
||||
{children.map(child =>
|
||||
<a href={app.route.tag(child)} config={m.route} onclick={e => e.stopPropagation()}>
|
||||
<a href={app.route.tag(child)} config={function(element, isInitialized) {
|
||||
$(element).on('click', e => e.stopPropagation());
|
||||
m.route.apply(this, arguments);
|
||||
}}>
|
||||
{child.name()}
|
||||
</a>
|
||||
)}
|
||||
|
@ -62,9 +62,6 @@
|
||||
&:hover {
|
||||
background: fade(#000, 5%);
|
||||
}
|
||||
&:active {
|
||||
background: fade(#000, 15%);
|
||||
}
|
||||
}
|
||||
.TagTile-name {
|
||||
font-size: 20px;
|
||||
@ -95,7 +92,7 @@
|
||||
line-height: 21px;
|
||||
opacity: 0.5;
|
||||
|
||||
&, &:hover, &:active {
|
||||
&, &:hover {
|
||||
background: fade(#000, 10%);
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user