diff --git a/[esx]/esx_notify/Notify.lua b/[esx]/esx_notify/Notify.lua new file mode 100644 index 00000000..8a54aca6 --- /dev/null +++ b/[esx]/esx_notify/Notify.lua @@ -0,0 +1,11 @@ +local function Notify(type, length, message) + SendNuiMessage(json.encode({ + type = type or "info", + length = length or 3000, + message = message or "ESX-Notify" + })) +end + +exports('Notify', Notify) +RegisterNetEvent("Notify", Notify) + diff --git a/[esx]/esx_notify/fxmanifest.lua b/[esx]/esx_notify/fxmanifest.lua new file mode 100644 index 00000000..16d7c135 --- /dev/null +++ b/[esx]/esx_notify/fxmanifest.lua @@ -0,0 +1,23 @@ +fx_version 'adamant' +game 'gta5' +author 'ESX-Framework' +description 'ESX Notification' + +shared_scripts { + '@es_extended/imports.lua', +} + +client_scripts { 'Notify.lua' } + +ui_page 'nui/index.html' + +files { + 'nui/index.html', + 'nui/js/*.js', + 'nui/css/*.css', + 'nui/img/*.png', +} + +exports { + 'Notify' +} \ No newline at end of file diff --git a/[esx]/esx_notify/nui/css/style.css b/[esx]/esx_notify/nui/css/style.css new file mode 100644 index 00000000..4b24467e --- /dev/null +++ b/[esx]/esx_notify/nui/css/style.css @@ -0,0 +1,14 @@ +:root { + --color: white; + --bgColor: #212121; +} + +* { + padding: 0; + margin: 0; +} + +body { + color: var(--color); + font-family: sans-serif; +} \ No newline at end of file diff --git a/[esx]/esx_notify/nui/index.html b/[esx]/esx_notify/nui/index.html new file mode 100644 index 00000000..e2064fe2 --- /dev/null +++ b/[esx]/esx_notify/nui/index.html @@ -0,0 +1,118 @@ + + +
+ + + + + + +