GithubHelp home page GithubHelp logo

webshell's Introduction

WebShell

WebShell is an OS X WebView shell, which help you easily bundle the Web Apps to native OS X app without coding.

Requirements

  • Xcode 7+ (Swift 2.0+ support)

Quick Start

$ git clone https://github.com/djyde/WebShell.git APP_NAME

$ cd APP_NAME && open WebShell.xcodeproj

Edit Sites/WebShell/Settings.swiftt and change the url whatever you like.

Finally click the run button to run the app.

Bonus Features

Demo

Document

For more detail configurations, please see document

Who's using WebShell

If you built any wonderful app with WebShell, just let me know!

License

MIT License

webshell's People

Contributors

0xwdg avatar antuankhanna avatar bumaociyuan avatar dibas avatar djyde avatar dreampiggy avatar fahimf avatar readmecritic avatar thehappydinoa avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

webshell's Issues

Swift 2.2 + Swift 3

  • Optimize for Swift 3 (Means no For loops in C-Style)
  • Fix errors and warnings for Swift 2.2

Support for OS X Mavericks (10.9.5)

OS X Mavericks still has ~15% market share, and Swift code is compatible with Mavericks because Xcode automatically embeds a runtime binary upon compilation.

However, symbol viewDidLoad is not available in Mavericks. Any chance to weak link that/add some sort of version check to make WebShell compatible with Mavericks?

Quit app when window is closed

An app I built with Webshell just got rejected from the app store with the following statement regarding the default behavior when the main window gets closed:

We have found that when the user closes the main application window there is no menu item to
re-open it. The app should implement a Window menu that lists the main window so it can be
reopened, or provide similar functionality in another menu item. OS X Human Interface Guidelines,
state that "The menu bar [a]lways contains [a] Window menu".

Alternatively, if the application is a single-window app, it might be appropriate to save data and quit the > app when the main window is closed. ''

As it is an single-window app it would be good to add the behavior as stated in the HIGuidlines.

Badge and Notification won't disappear

We I clicked the notifications, the notifications still stayed there after the app window launched. So did the badge.

点击通知后通知没有自动消失(把多个也是如此)

Webshell for iOS

Maybe it's good to also make a iOS version.

With the local notifications and maybe some other enhancements.

Fix "new window".

If i launch a new window the 'main window' wil freeze.

  • the recently launched screen will not become on top.

add https to the quickstart on the cloning instruction

I was getting

Permission denied (publickey).
fatal: Could not read from remote repository.

Please make sure you have the correct access rights
and the repository exists.

without the https on git clone github.com/djyde/WebShell.git APP_NAME

Preserve local storage

From what I can tell, local storage is not preserved after quitting the WebShell application. This means for applications that use local storage to save information such as authentication tokens, they are lost when exiting the application resulting in the user having to re-login.

Any idea on how to get local storage to be preserved after exiting the application?

Add geolocation support

Right now this code never runs a callback, it is probably something with permissions.

navigator.geolocation.getCurrentPosition(function(position) {
  console.log(position);
});

File download

Hello,

when I try download PDF file directly from link (or right click > Download Linked File) - will be only opened in app and I cann't go home/back etc.
and any other filetypes I cannot download.

will be possible download files to Downloads dir?

Injecting javascript is too slow

If i set the url to http://wdg.github.io/HTML-iOS-Template/mac.html
wich contains a test what uses window.webshell.version a.k.a. webshell.version.
i'd need to create a hack because the injecting is somewhat to slow.

The function:

function myFunction() {
    if (typeof window.webshell !== 'undefined') {
        console.log(window.webshell.version) // works...
    } else {
        console.error('i\'m missing something')
    }
}

the hack:

rdy(function(){myFunction()});
function rdy(f){/in/.test(document.readyState)?setTimeout('rdy('+f+')',9):f()}

this test every 9ms the readyState.

because window.addEventListener is too fast, and injecting to slow.

window.addEventListener(
    "load",
    function(event) { myFunction() },
    true
); // missed it, to early

window.addEventListener(
    "load",
    function(event) { myFunction() },
    false
); // missed it, to early

window.addEventListener(
    "DOMContentLoaded",
    function(event) { myFunction() }, 
    true
); // missed it, to early

window.addEventListener(
    "DOMContentLoaded",
    function(event) { myFunction() },
    false
); // missed it, to early

Possible solutions:

  • Try to inject the javascript faster.
  • Extend WebKit (don't know if it is possible, in this way)
  • Fire the DOMContentLoaded, load 2 times (last time by WebShell)

file upload disable fakepath

will be possible disable fakepath when upload file? current webkit implement [html5's fakepath](HTML5's fakepath) because of security, but native app should handle it with nodejs or others, so disable this feature will be nice when develop native app.

When I click a notification in Notification Centre, nothing happened

When a user clicked a notification in Notification Centre, it supposed to bring user to the corresponding app, but now, nothing happened.

在通知中心点击通知后,没有任何对应动作发生,然后通知中心内的对应条目也不会消失(在自己打开 app 查看信息后)

Add back and forward buttons

Only if available

I link it to #31 (as the Contextmenu issue, this issue is for building a good bug and enhancement history)

iOS

Can you made Notification API to work on iOS ?

Trackpad gestures?

Back/forward with gestures doesn't seem to work. The keyboard shortcuts seem to work fine.

possible to reference local files?

Does WebShell allow to point to a local (i.e index.html) file within the package and not to a remote URL? If yes, how would one reference and include a local file? Thanks.

Support for printing

It doesn't seem like printing is supported, as CMD+P doesn't bring up the native print dialog, and webpages that have Print buttons don't bring up the native print dialog either.

incorrect mock implementation for Notification.requestPermission

your implementation

Notification.requestPermission = function(callback) {
    if (typeof callback === 'function') {
        callback();
        return true
    } else {
        return true
    }
};

while I think the following codes should be more suitable for real environment

Notification.requestPermission = function(callback) {
    if (typeof callback === 'function') {
        callback('granted');
    } 
};

File upload

Hello,

will be possible allow file upload from form input?

Thx4reply

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.