os-js / osjs-client Goto Github PK
View Code? Open in Web Editor NEWOS.js Client Module
Home Page: https://manual.os-js.org/
License: Other
OS.js Client Module
Home Page: https://manual.os-js.org/
License: Other
There should be some menu fixes in v3.
Menu should be using a little different color to be separated with top panel. They are currently both black so it it not possible to separate them. This is also problem in other (context) menus. You could also enable color changes in settings app.
You should also reorganize categories in menu, by alphabet or functionally. This could also be changed in settings.
Also, some apps (Welcome, Settings) still don't have icon.
@pkipjames on Gitter had some connectivity issues and was spammed with notifications.
This event could use a debounce so that it does not trigger unless the user has been inactive for X seconds.
Ref: https://github.com/os-js/osjs-client/blob/master/src/core.js#L238
maybe it's just for autostart. But, the application does not reload when the user clicks on "reload" in the menu option.
Also, when npm run build:dist is completed, the apps that are set to autostart, disappear and fail to reload. Likely similar issue.
Currently, the only way to select what packages a user can use is:
metadata.json
in a package. Which does not really solve this problem. This is usually only applicable to things that requires admin access.blacklist
in the authentication adapters. Which is kind of the opposite of what is suggested here.So, my thought is just to add a configuration option for this, ex.:
{
packages: {
users: {
username: {
allow: ['A'],
deny: ['B']
}
}
}
}
This will allow for doing whitelisting and blacklisting.
Need a programmatic way to prevent users from changing anything about the applications/widgets. Maybe based on user roles.
A bunch of windows manager has shading and unshading so it'd be cool so have that too.
Originally created here: os-js/OS.js#684
The Z-Index of Notifications seem to be wrong.
@SpaceboyRoss01 pointed out in os-js/OS.js#671 that windows does not focus automatically and perceived this as a bug.
It's actually by design, though if this is the right choice -- is up for discussion.
So I'm thinking there's three possibilities here... or fourth which is to have it focus by default, but maybe add some kind of focus stealing prevention (or honor ICCCM).
Right now you have to do, ex:
.createWindow()
.render()
.focus()
Ex:
proc = core.make('osjs/application', {
options: Object.assign({
autofocusWindow: Boolean
}, options)
});
https://github.com/os-js/osjs-client/blob/master/src/application.js#L53
Ex:
createWindow({
focused: true
})
https://github.com/os-js/osjs-client/blob/master/src/window.js#L47
Ex:
{
desktop: {
autofocusWindow: Boolean
}
}
https://github.com/os-js/osjs-client/blob/master/src/config.js#L102
I'd like to suggest some feature request because I need to customize desktop and login views without modifying client (core) sources.
I see you use hyperapp
at https://github.com/os-js/osjs-client/blob/master/src/login.js#L1
my guess it's not a good approach because core files should be separated from applications.
As well as login the desktop solution could be provided as a separate application.
@andersevenrud Hope you can implement the necessary feature or provide motivated rejection.
I could also spend some time to make this changes for you if you don't have a time for it.
core.make("osjs/package").install(url)
should be a function, it should install the application/package and restart the server and refresh the page.
Add back the desktop iconview.
Desktop
Ref:
https://manual.os-js.org/v3/guide/login/
It would be nice to be able to set an image above the "Welcome..." line.
Perhaps using a parameter for "North", "South", "East", "West" to set the image to the top, bottom, right, or left of the login input fields. OS.js could configure it to fit the max width/height of each zone with some padding adjustments. Just a thought on this part.
If the user walks away from OS.js (or opens a separate tab on the browser), OS.js should automatically log out and force the user to log back in.
Maybe a global client setting. inactivity.timeout=30000
In my clocks app, the application is a static window on the screen. The user cannot resize it, move it, hide it, nor close it.
In v3 (in v2 I did a similar thing) I added to my clocks css:
.Window_WorldClocks > .osjs-window-inner > .osjs-window-header {
display: none !important;
}
I think there ought to be a better way to do this. Give developers the ability to turn off window resizing, and also remove the header if they wish (removing the header can be separate from resizing, so it looks like a splash screen in a sense but the window is movable).
Perhaps in metadata.json file something like:
"resizable" : true/false,
"show-header" : true/false
Main issue here: os-js/osjs-panels#14
From os-js/OS.js#423
Add support to use several browser windows to mimic/implement a multi-head system with several screen monitors. In a first step would be just enough to use window.open() function and postMessage() to comunicate between main and auxiliar windows (or better, move core functionality to a SharedWorker and windows doing requests to it), and in the long term allow to use windows on several independent devices (smartphone, tablet...) to extend the desktop area or show notifications or for an auxiliar tools panel.
currently, I have to manually git clone the git repo and run the npm i command.
Would be nice if the same npm run install:package -- https://github.com/os-js/osjs-example-application.git
would work on a gitlab repo as well.
Being able to change the position where the notifications appear as well as possibly the color would be a nice touch.
Set the attribute to something like:
attributes: {movable: false}
Applications should have a list of permissions to access specific things, this could be useful for security reasons so the user could stop a specific application from doing malicious things.
Add support for setting percentages as initial window dimensions.
This will not work when you start resizing stuff etc, so it would have to be reset to pixels when that occurs.
It would be nice if when the desktop was set up to use a wallpaper and the source was null
this would redact the background-image
style and use the CSS defaults.
I feel like it is better to have a proper lock screen rather than saving the session and logging out.
Sort of like how "lightbox" works in webpages, i.e. screen blackout.
When a filesystem cannot be watched by the server, the client should emit these events.
The server already emits the following event when a filesystem is set to watch (and the adapter can support this):
osjs/vfs:watch:change
{
source: 'server',
path: 'mount:/path/to/directory',
action: 'unlinkDir',
type: 'remove'
}
This is the event action/type map:
Action | Type |
---|---|
add | add |
addDir | add |
unlink | remove |
unlinkDir | remove |
Found some bug while debugging alpha version under Windows:
GET / 304 - - 15.697 ms
GET /vendors~osjs.js 304 - - 6.258 ms
GET /osjs.css 304 - - 9.628 ms
Error: EPERM: operation not permitted, rename 'USER\PATH\TO\OS.js\sessions\DFD8yoOxvCNf8KsFBuy4s4gPwPvqAVhk.json.284074389' -> 'USER\PATH\TO\OS.js\sessions\DFD8yoOxvCNf8KsFBuy4s4gPwPvqAVhk.json'
GET /osjs.js 304 - - 12.345 ms
Error: EPERM: operation not permitted, rename 'USER\PATH\TO\OS.js\sessions\DFD8yoOxvCNf8KsFBuy4s4gPwPvqAVhk.json.1103784534' -> 'USER\PATH\TO\OS.js\sessions\DFD8yoOxvCNf8KsFBuy4s4gPwPvqAVhk.json'
POST /login 200 52 - 18.567 ms
GET /f4cfc6708cf6bfc17d4b1e775f594ae2.png 304 - - 11.639 ms
GET /metadata.json 304 - - 4.328 ms
GET /themes/Standard/index.css 304 - - 10.519 ms
GET /favicon.png 200 7625 - 6.907 ms
OS: Windows 10 64bit
The result is the empty screen (without panels and desktop) after login.
@andersevenrud I'll debug it today but it would be nice if you put your assumptions what cause this issue.
Note: I installed OS.js v3 strictly according the manual: https://manual.os-js.org/v3/install/#setup
There should be a way to reload the client without refreshing the page. This would help with BlueLight so it wouldn't require you to reboot to reload the client saving time.
Support for defining aspect ratios to windows.
When user tries to use arrow keys in Firefox, they will be ignored because of user-select: all
(auto as well).
Original issue: os-js/osjs-gui#8
I had this in v2 and should be back-ported. Basically add an attribute to the root element that sets all text CSS styles to RTL.
If a custom application socket connection drops, it's never re-established (the internal one does though).
From os-js/osjs-server#8
Finish the APIs for making VFS instances via the client.
I think that it'd be cool to have workspaces like what many operating systems and desktop environments have.
Currently when you change the settings in src/client/index.js
of the distro, these will not be transitioned because users might have local settings stored.
By adding support for a revision
number these settings could be reset automatically easily (simply load core settings on login instead of the user ones).
Also, adding support for custom migration scripts would be pretty neat so no custom settings would be lost.
revision
config optionRef: #76
Per discussion with Anders:
So if the desktop resizes, they will overflow if viewport becomes smaller.
This is what "maximized" is for. Maybe adding a "maximum maximized size" is an option, but that kind of defeats "maximisation".
Need to be able to set percentages for the dimensions, ex: width: 100% or something to that effect
Since service providers hooks into the bootstrapping, they can delay the UI and application launching.
Add some sort of loading screen with progress bar.
It would be cool if the window manager was a package that would be installed so if someone wanted a different window manager, they just change some settings and the new window manager is the applied.
This might have something to do with restoration, but the data-media
state is not correct whenever a window is restored or inited late.
The media attribute is also not updated whenever a window is maximized or restored to previous state.
In metadata.json I have:
"singular": true,
"autostart": true,
The package/app is not starting up when launching the server. I think there was a setting for turning of resizing of the window, can't seem to find that either, I did see win.setSize() functions though - maybe I looked in the wrong part of the new docs?
When windows are on-top (like error dialogs), in some cases they won't stack on-top properly on initial creation.
Stumbled on a problem with core.url() trying to create a websocket connection. core.url does not return a valid websocket uri to use with the core.make("osjs/websocket") call. Sample code:
const uri = this.core.url("/socket");
const ws = this.core.make("osjs/websocket", 'mySocket', uri);
ws.on("message", event => {
console.log("websocket message received... yay!\n", event.data);
});
ws.on("open", event => {
console.log("websocket opened... yay!\n", event);
});
ws.on("close", event => {
console.log("websocket closed... oh no!\n", event);
entry.destroy();
});
ws.on("error", event => {
console.log("websocket error: ", event);
});
when I use let packages = this.core.make('osjs/packages');
and I try to access packages.running
, it returns undefined
and this should be fixed.
If OS.js will be opened in NW.js, is there any restrictions of using "webview" tag instead of iframe for implementing browser for third-party web pages?
Recently on the OS.js gitter, I said:
I think that if you set a window's position to a string instead of an object, like position: "center" it would center the window on the screen.
So, this should be implemented. The different position strings should be "center"
, "top-left"
, "top-right"
,"top-center"
, etc.
Maybe have some sort of option for a method to periodically (or after interaction) save the application state so that the user don't have to explicitly select "Log out and save session" ?!
A binding like having Alt+C should close the focused window.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.