Skip to content

Commit

Permalink
Merge pull request #10834 from DestinyItemManager/organizer-traits
Browse files Browse the repository at this point in the history
Organizer: Separate traits into two columns
  • Loading branch information
chainrez authored Dec 8, 2024
2 parents ecec5e9 + 432274c commit a14bace
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 11 deletions.
9 changes: 4 additions & 5 deletions src/app/organizer/Columns.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -995,7 +995,9 @@ function D1PerksCell({ item }: { item: D1Item }) {
<BungieImage src={p.icon} />
</div>{' '}
{p.name}
{(!p.unlocked || p.xp < p.xpRequired) && <> ({percent(p.xp / p.xpRequired)})</>}
{p.xpRequired > 0 && (!p.unlocked || p.xp < p.xpRequired) && (
<> ({percent(p.xp / p.xpRequired)})</>
)}
</div>
</PressTip>
),
Expand Down Expand Up @@ -1027,10 +1029,7 @@ function perkString(sockets: DimSocket[]): string | undefined {
.join(',');
}

function getSockets(
item: DimItem,
type?: 'all' | 'traits' | 'barrel' | 'shaders' | 'origin',
): DimSocket[] {
function getSockets(item: DimItem, type?: 'all' | 'traits' | 'shaders' | 'origin'): DimSocket[] {
if (!item.sockets) {
return [];
}
Expand Down
10 changes: 5 additions & 5 deletions src/app/organizer/ItemTable.m.scss
Original file line number Diff line number Diff line change
Expand Up @@ -181,24 +181,24 @@ $content-cells: 5;

.perks,
.traits,
.barrels,
.intrinsics,
.originTrait,
.shaders {
padding-top: calc(var(--item-size) * 0.5 * 0.5 - 5px) !important;
}
.perks {
.perks,
.traits {
columns: 2;
height: 100%;
box-sizing: border-box;
column-gap: 8px;
> *:nth-last-child(n + 2) {
margin-bottom: 4px;
}
&.header {
display: flex;
flex-direction: column;
}
> *:nth-last-child(n + 2) {
margin-bottom: 4px;
}
}

.modPerks {
Expand Down
1 change: 0 additions & 1 deletion src/app/organizer/ItemTable.m.scss.d.ts

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit a14bace

Please sign in to comment.