Skip to content

Commit

Permalink
feat: fl-configs v0.14.0 update
Browse files Browse the repository at this point in the history
  • Loading branch information
dd84ai committed Mar 28, 2024
1 parent 473eed6 commit f0ed09a
Show file tree
Hide file tree
Showing 4 changed files with 15 additions and 3 deletions.
2 changes: 0 additions & 2 deletions darkstat/front/shared.templ
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,6 @@ templ TabContent() {
padding-bottom: 2px;
padding-top: 2px;
padding-right: 5px;


}

table, tr,th, td, thead {
Expand Down
12 changes: 12 additions & 0 deletions darkstat/linker/linker.go
Original file line number Diff line number Diff line change
Expand Up @@ -45,21 +45,33 @@ func (l *Linker) Link() *builder.Builder {
data := l.configs.Export()

sort.Slice(data.Bases, func(i, j int) bool {
if data.Bases[i].Name != "" && data.Bases[j].Name == "" {
return true
}
return data.Bases[i].Name < data.Bases[j].Name
})

for _, base := range data.Bases {
sort.Slice(base.MarketGoods, func(i, j int) bool {
if base.MarketGoods[i].Name != "" && base.MarketGoods[j].Name == "" {
return true
}
return base.MarketGoods[i].Name < base.MarketGoods[j].Name
})
}

sort.Slice(data.Factions, func(i, j int) bool {
if data.Factions[i].Name != "" && data.Factions[j].Name == "" {
return true
}
return data.Factions[i].Name < data.Factions[j].Name
})

for _, faction := range data.Factions {
sort.Slice(faction.Reputations, func(i, j int) bool {
if faction.Reputations[i].Name != "" && faction.Reputations[j].Name == "" {
return true
}
return faction.Reputations[i].Name < faction.Reputations[j].Name
})
}
Expand Down
2 changes: 1 addition & 1 deletion go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ go 1.21.1

require (
github.com/a-h/templ v0.2.543
github.com/darklab8/fl-configs v0.13.2
github.com/darklab8/fl-configs v0.14.0
github.com/darklab8/go-typelog v0.6.0
github.com/darklab8/go-utils v0.12.0
github.com/yosssi/gohtml v0.0.0-20201013000340-ee4748c638f4
Expand Down
2 changes: 2 additions & 0 deletions go.sum
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,8 @@ github.com/darklab8/fl-configs v0.13.1 h1:C/8JD9eVGkxW5PGKwf5Sp7IvopJpbF+5L2v6yN
github.com/darklab8/fl-configs v0.13.1/go.mod h1:8zaCaFL21TvawP65KB9NOJ+nEpaMDQYsnoOi77RiSVY=
github.com/darklab8/fl-configs v0.13.2 h1:HIWrZI4z5PdEba3qkugzz1Ysl7UTJNmvsGTezjivXZw=
github.com/darklab8/fl-configs v0.13.2/go.mod h1:8zaCaFL21TvawP65KB9NOJ+nEpaMDQYsnoOi77RiSVY=
github.com/darklab8/fl-configs v0.14.0 h1:YtK83tiltJpbYd6X8QiLxSIjhFxgBjmXI+IrDSYph60=
github.com/darklab8/fl-configs v0.14.0/go.mod h1:8zaCaFL21TvawP65KB9NOJ+nEpaMDQYsnoOi77RiSVY=
github.com/darklab8/go-typelog v0.6.0 h1:Ci8imc7ScXiy5e1qMgf46NyJjrqNLPoIE1gbVe7bxl4=
github.com/darklab8/go-typelog v0.6.0/go.mod h1:AwwOf3dkp/tpevHFNbkB+PbwlDrUUgO1CVFkEnj+q5w=
github.com/darklab8/go-utils v0.12.0 h1:LxsG3yVNf9W4xyV+tHPOaZB2ewItgM/1BzOXyKFvofs=
Expand Down

0 comments on commit f0ed09a

Please sign in to comment.