Skip to content

Commit 5afefb4

Browse files
committed
Merge CfxUI update (mr-911)
06efa44 - feat(ext/ui): 2026.2 update 73e1e4b - fix(nui-core): trust ui_url overrides
2 parents c3bc129 + 06efa44 commit 5afefb4

333 files changed

Lines changed: 76 additions & 40994 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

.gitattributes

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -27,5 +27,3 @@ code/components/voip-mumble/include/lib*/** linguist-vendored
2727
ext/natives/natives_stash/* linguist-generated
2828
*.p linguist-generated
2929

30-
# ensure cfx-ui is using autocrlf
31-
ext/cfx-ui/** text=auto

code/components/nui-core/src/NUIClient.cpp

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,13 +34,18 @@ static nui::IAudioSink* g_audioSink;
3434

3535
static bool IsTrustedEntitlementFrame(const std::string& frameUrl)
3636
{
37+
static ConVar<std::string> uiUrlVar("ui_url", ConVar_UserPref, "https://nui-game-internal/ui/app/index.html");
38+
if (boost::algorithm::starts_with(frameUrl, uiUrlVar.GetValue()))
39+
{
40+
return true;
41+
}
42+
3743
if (frameUrl.empty())
3844
{
3945
return false;
4046
}
4147

4248
CefURLParts urlParts;
43-
4449
if (!CefParseURL(frameUrl, urlParts))
4550
{
4651
return false;

code/tools/build/run_postbuild.ps1

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -58,12 +58,12 @@ if ($Game -eq "server") {
5858
if (!$IsServer) {
5959
## build UI
6060
Push-Location $WorkDir
61-
$UICommit = (git rev-list -1 HEAD ext/ui-build/ ext/cfx-ui/)
61+
$UICommit = (git rev-list -1 HEAD ext/ui-build/)
6262
Pop-Location
6363

6464
Push-Location $WorkDir\ext\ui-build
6565
if (!(Test-Path data\.commit) -or $UICommit -ne (Get-Content data\.commit)) {
66-
.\build.cmd | Out-Null
66+
.\build.cmd $Game | Out-Null
6767

6868
$UICommit | Out-File -Encoding ascii -NoNewline data\.commit
6969
}

code/tools/ci/psm1/cfxBuildUI.psm1

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -15,13 +15,10 @@ function Invoke-BuildUI {
1515
$haveNewerCommit = $Versions.UICommit -ne (Get-Content -ErrorAction Ignore $lastBuiltCommitFile)
1616

1717
if (!$havePreviouslyBuiltArtifacts -or $haveNewerCommit) {
18-
cmd /c build.cmd
18+
cmd /c build.cmd $($Context.PremakeGameName)
1919
Test-LastExitCode "Failed to build CfxUI"
2020

2121
$Versions.UICommit | Out-File -Encoding ascii -NoNewline $lastBuiltCommitFile
22-
23-
# delete node_modules to avoid them polluting the build cache
24-
Remove-Item -Recurse -Force $Context.getPathInProject("ext\cfx-ui\node_modules")
2522
} else {
2623
Write-Output "Skipping UI build: existing artifacts are up to date"
2724
}

code/tools/ci/psm1/cfxVersions.psm1

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -96,7 +96,6 @@ function Get-CfxVersions {
9696
$versions.SDK = ((git rev-list $versions.SDKCommit | measure-object).Count * 10) + 1100000
9797

9898
$UIPaths = @(
99-
"ext/cfx-ui/"
10099
"ext/ui-build/"
101100
)
102101
$versions.UICommit = (git rev-list -1 HEAD $UIPaths)

ext/README.md

Lines changed: 15 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -1,17 +1,16 @@
1-
# CitizenFX External Projects
2-
3-
This directory contains external projects which are _generally_ part of the core build in some way, but not considered
4-
part of the main project.
5-
6-
## ext/
7-
* [**cfx-ui/**](./cfx-ui): The main menu interface for the game clients.
8-
* [**event-doc-gen/**](./event-doc-gen): Generation tooling for _event_ documentation.
9-
* [**native-decls/**](./native-decls): Native function declarations for `CFX/` natives defined in the main project.
10-
* [**native-doc-gen/**](./native-doc-gen): Scripts to generate `native-decls` using the `native-doc-tooling` submodule.
11-
* [**native-doc-tooling/**](./native-doc-tooling): A submodule for the latest version of `native-doc-tooling`, which is used to generate native definitions from the documentation in `native-decls`.
12-
* [**natives/**](./natives): Code generation tooling to convert a native function database in 'intermediate' Lua format to runnable Lua/JS/C# and other intermediate formats.
13-
* [**nuget/**](./nuget): Build files for the `CitizenFX.Core.Client` and `CitizenFX.Core.Server` NuGet packages.
14-
* [**symbol-upload/**](./symbol-upload): A tool to collect Linux build symbols to upload to a .NET Core-style symbol server.
15-
* [**system-resources/**](./system-resources): System resources bundled with FXServer by default.
16-
* [**typings/**](./typings): Build files for the `@citizenfx/client` and `@citizenfx/server` NPM packages.
1+
# CitizenFX External Projects
2+
3+
This directory contains external projects which are _generally_ part of the core build in some way, but not considered
4+
part of the main project.
5+
6+
## ext/
7+
* [**event-doc-gen/**](./event-doc-gen): Generation tooling for _event_ documentation.
8+
* [**native-decls/**](./native-decls): Native function declarations for `CFX/` natives defined in the main project.
9+
* [**native-doc-gen/**](./native-doc-gen): Scripts to generate `native-decls` using the `native-doc-tooling` submodule.
10+
* [**native-doc-tooling/**](./native-doc-tooling): A submodule for the latest version of `native-doc-tooling`, which is used to generate native definitions from the documentation in `native-decls`.
11+
* [**natives/**](./natives): Code generation tooling to convert a native function database in 'intermediate' Lua format to runnable Lua/JS/C# and other intermediate formats.
12+
* [**nuget/**](./nuget): Build files for the `CitizenFX.Core.Client` and `CitizenFX.Core.Server` NuGet packages.
13+
* [**symbol-upload/**](./symbol-upload): A tool to collect Linux build symbols to upload to a .NET Core-style symbol server.
14+
* [**system-resources/**](./system-resources): System resources bundled with FXServer by default.
15+
* [**typings/**](./typings): Build files for the `@citizenfx/client` and `@citizenfx/server` NPM packages.
1716
* [**ui-build/**](./ui-build): Scripts and data files for building `citizen/ui.zip` including root helpers, legacy UI scripts and a packed version of `cfx-ui`.

ext/cfx-ui/.editorconfig

Lines changed: 0 additions & 9 deletions
This file was deleted.

ext/cfx-ui/.eslintignore

Lines changed: 0 additions & 4 deletions
This file was deleted.

ext/cfx-ui/.eslintrc.cjs

Lines changed: 0 additions & 44 deletions
This file was deleted.

ext/cfx-ui/.gitignore

Lines changed: 0 additions & 86 deletions
This file was deleted.

0 commit comments

Comments
 (0)