mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-11-24 05:11:16 +00:00
Bug 1804352 move richlistitem inline styling to sitePermissions.css r=settings-reviewers,Gijs
Differential Revision: https://phabricator.services.mozilla.com/D172084
This commit is contained in:
parent
1ea516e3f4
commit
e2787b30fe
@ -20,6 +20,34 @@ hbox.website-status {
|
||||
min-height: 35px;
|
||||
}
|
||||
|
||||
#permissionsBox > richlistitem > hbox {
|
||||
flex: 1;
|
||||
}
|
||||
|
||||
#siteCol {
|
||||
flex: 3 3 auto;
|
||||
}
|
||||
|
||||
.website-name {
|
||||
flex: 3 3;
|
||||
}
|
||||
|
||||
#statusCol {
|
||||
flex: 1 auto;
|
||||
}
|
||||
|
||||
.website-status {
|
||||
flex: 1;
|
||||
}
|
||||
|
||||
/* TODO(bug 1802993): Seems this could be on .website-name instead of label? */
|
||||
#siteCol,
|
||||
#statusCol,
|
||||
.website-name > label,
|
||||
.website-status {
|
||||
width: 75px;
|
||||
}
|
||||
|
||||
menulist.website-status {
|
||||
margin: 1px;
|
||||
margin-inline-end: 5px;
|
||||
|
@ -401,19 +401,14 @@ var gSitePermissionsManager = {
|
||||
},
|
||||
|
||||
_createPermissionListItem(permissionGroup) {
|
||||
let width = "75px";
|
||||
let richlistitem = document.createXULElement("richlistitem");
|
||||
richlistitem.setAttribute("origin", permissionGroup.origin);
|
||||
let row = document.createXULElement("hbox");
|
||||
row.setAttribute("style", "flex: 1");
|
||||
|
||||
let hbox = document.createXULElement("hbox");
|
||||
let website = document.createXULElement("label");
|
||||
website.setAttribute("value", permissionGroup.origin);
|
||||
// TODO(bug 1802993): Seems this could be on the hbox instead or something?
|
||||
website.setAttribute("style", `width: ${width}`);
|
||||
hbox.setAttribute("class", "website-name");
|
||||
hbox.setAttribute("style", `flex: 3 3`);
|
||||
hbox.appendChild(website);
|
||||
|
||||
let states = SitePermissions.getAvailableStates(this._type).flatMap(
|
||||
@ -457,7 +452,6 @@ var gSitePermissionsManager = {
|
||||
this.onPermissionChange(permissionGroup, Number(siteStatus.value));
|
||||
});
|
||||
}
|
||||
siteStatus.setAttribute("style", `flex: 1; width: ${width}`);
|
||||
siteStatus.setAttribute("class", "website-status");
|
||||
siteStatus.value = permissionGroup.capability;
|
||||
|
||||
|
@ -49,9 +49,9 @@
|
||||
</hbox>
|
||||
<separator class="thin"/>
|
||||
<listheader>
|
||||
<treecol id="siteCol" data-l10n-id="permissions-site-name" style="flex: 3 3 auto; width: 75px"
|
||||
<treecol id="siteCol" data-l10n-id="permissions-site-name"
|
||||
onclick="gSitePermissionsManager.buildPermissionsList(event.target)"/>
|
||||
<treecol id="statusCol" data-l10n-id="permissions-status" style="flex: 1 auto; width: 75px"
|
||||
<treecol id="statusCol" data-l10n-id="permissions-status"
|
||||
data-isCurrentSortCol="true"
|
||||
onclick="gSitePermissionsManager.buildPermissionsList(event.target);"/>
|
||||
</listheader>
|
||||
|
Loading…
Reference in New Issue
Block a user