Giter VIP home page Giter VIP logo

sproutcore's Introduction

Gitter Build Status

SproutCore 2: For Native-Caliber Web Apps

Sproutcore 2 no longer support the Abbot Buildtools which has been replaced by the new Node.js Build Tools.

SproutCore is a JS-MVC framework for building blazing-fast, native-caliber web applications. SproutCore's full-stack approach to single-page application development gives you the tools you need to build rich, powerful applications... which happen to run in the browser.

Getting Started

The easiest way to get started with SproutCore is to install the Ruby gem. You can find instructions here. Once you've got SproutCore installed, checkout the Getting Started tutorial.

Next Steps

Once you're through the Getting Started tutorial:

Support

Resources for SproutCore developers include the docs for API documentation, and the Guides for a series of topical walk-throughs.

For additional SproutCore user support, join the mailing list, or stop by the #sproutcore IRC channel. For those interested in contributing to the framework itself, please join [email protected].

Acknowledgements

SproutCore includes code from a number of different open source projects including:

sproutcore's People

Contributors

ashiks avatar bjc avatar dcporter avatar endash avatar etgryphon avatar geoffreyd avatar gmoeck avatar jameschao avatar joubertnel avatar krotscheck avatar lawrencepit avatar martoche avatar mauritslamers avatar mirion avatar mlcohen avatar nicolasbadia avatar nirumalthomas avatar onkis avatar publickeating avatar rbu avatar santhakumar avatar santoshshan avatar teresa-zz avatar thomaslang avatar tim-evans avatar unicolet avatar vikingstad avatar wagenet avatar wemrysi avatar wycats 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  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

sproutcore's Issues

Custom renderer somehow loses class set in initial render() on an update()

Back in Quilmes I did a context.setClass('custom-view', YES) in my renderer's render() and it kept that class for the lifetime of that view.

In the new quilmes-master merged master, my view somehow loses the 'custom-view' class on the renderers update(), so now I have to again set 'custom-view' class on each update().

sproutcore 1.4 on windows

currently, it looks like the eventmachine native extension build fails during a run of gem install sproutcore. from a basic bit of poking around on google, it appears that eventmachine is a notorious pain to build on windows via gem.

I know this is really a problem with an upstream dependency, so it's more of a "heads up" than a "hey you guys fix this!"

Personally, I run sproutcore on either linux or a linux guest on windows, but I was curious what would happen in this case and wanted to share those results. I assume this is something that's changed in the build tools, as I recall that sproutcore 1.0 worked in windows without issue.

Picker pointer popups no longer show the pointer with the new Ace theme

Using code from sproutcore-samples:

var pickerPane = SC.PickerPane.create({
  layout: { width: 300, height: 200 },
  contentView: SC.View.extend({
    layout: { top: 0, left: 0, bottom: 0, right: 0 },
  })
});
pickerPane.popup(itemView, SC.PICKER_POINTER, [3,0,1,2,2]);

This no longer shows the little pointer.

Dynamically Changing TabView Items

I have a Tab View that I am dynamically swapping the items that populate the Segment View portion depending on a selection in a Collection View.

Functionally everything is working as expected, but issue that I am having is related to "clipping" of the Segmented View portion. When selecting a Collection View item that would result in adding additional items to the Tab View, the Segmented View is "clipped" to only show an area based on the previous size.

If the browser window loses focus, all Segments seem to update to the desired rendered results. If an individual Segment is selected (even clicking the area that it should be showing in, even though it is not visible), that Segment is updated proper.

You can see a screen grab of the results at:

http://skitch.com/jaehess/dha6w/yesterday-149-messages

Chrome does seem to render everything properly, Safari is acting as described above.

Remove SC.Button

SC.Button seems to only be used from SC.ButtonView, and as such, is only adding load-time overhead and making SproutCore more complicated and difficult to understand.

It should be folded in to SC.ButtonView.

$().view() broken for SC.TableCell

When call on the DOM element corresponding to an instance of SC.TableCell, the $().view() does not return the SC.TableCell view. Instead it returns the SC.Table view.

The cause for this bug is that the function init() for SC.TableCell does not call sc_super(), and so SC.TableCell never gets registered in the SC.View.views object.

sc_static() mixes up files with same end names

I found that sc_static('male.png') and sc_static('female.png') both translated to the path to the female.png image. I tried it with a longer filename like 'man.png' and 'thisisnotaman.png' and found the same result.

TableView currently broken on master

following the TableView tutorial using the master branch leads to:
javascript.js:6746TypeError: Result of expression 'this._viewRenderer' [undefined] is not an object.
in the renderViewSettings: function(context, firstTime) method

couldn't figure out where exactly it breaks but was able to reproduce several times
switching to the 1-4-stable branch avoids the issue

the table_view example on demo.sproutcore.com is broken as well

It does not look like custom SC.ListView row heights work.

According to the docs and code comments custom SC.ListView row heights should work something like this:

Pos.mainPage = SC.Page.design({
  mainPane: SC.MainPane.design({
    childViews: ['mainView'],

    mainView: SC.ListView.design({
      contentBinding: 'Pos.posController.arrangedObjects',

      contentIndexRowHeight: function(view, content, contentIndex) {
        return 36;
      },

      customRowHeightIndexes: function() {
        var content = this.get('content');
        var indexes = SC.IndexSet.create();

        if (content)
          indexes.add(0, content.get('length'));

        return indexes;
      }.property('[]'),
    }),
  }),
});

The console log shows customRowHeightIndexes is fired every time something is added to or removed from content but it only works the first time customRowHeightIndexes is fired. You can work around the problem by manually firing customRowHeightIndexesDidChange.

SC.SceneView needs updating

SC.SceneView is over a year old and doesn't take into account any of the new animation code. As soon as we get the animate method fully supported, we should switch it over to use that.

SC.CascadeDataSource#retrieveRecords masks the ids parameter.

SC.DataSource#retrieveRecords takes the parameters (store, storeKeys, ids), whereas SC.CascadeDataSource#retrieveRecords takes the parameters (store, storeKeys).

My proposed fix is to change all store.call(store, ...) with store.apply(store, arguments).
This is much safer, and prevents having to edit the code even if the parameters change.

EDIT:
I've added a pull request that fixes this and adds tests to SC.CascadeDataSource.
#91

Radiobuttons are positioned incorrectly on Linux

You can see this in the Tasks control bar at the bottom

Worked around in Tasks using hacks below

.mozilla.windows .control-bar .sc-radio-view.sc-layout-horizontal .sc-radio-button {
margin-top: -12px;
}
.chrome.windows .control-bar .sc-radio-view.sc-layout-horizontal .sc-radio-button,
.safari.windows .control-bar .sc-radio-view.sc-layout-horizontal .sc-radio-button,
.safari.mac .control-bar .sc-radio-view.sc-layout-horizontal .sc-radio-button {
margin-top: 4px;
}

mouseEntered on second view is called before mouseExited of first

If you have two views side by side with mouseEntered/mouseExited events and mouse into the second view from the first, the second view's mouseEntered is called BEFORE the first view's mouseExited.

This causes a lot of headache if you want to e.g. have a shared state between a set of list items.

It's also counter-intuitive when you have a knowledge of statecharts.

SC.RecordArray.refresh() adds but doesn't remove records

It seems there is a problem with SC.RecordArray.refresh(), or rather SC.Store.refreshQuery().
After adding and removing records from the back-end, calling refresh() adds the new records, but doesn't remove deleted ones, so the resulting SC.RecordArray doesn't match the result of the fetch query.

Calling reset() on the stores doesn't help (or doesn't work?, they still contain the deleted elements), but will cause an internal inconsistency.

MasterDetailView popover doesn't show correctly on later opens

If you use MasterDetailView and use its popover feature, the popover will be openable when in portrait mode. However, if you open it, then switch to landscape (with it still open; it closes on its own), and then switch back to portrait and try to open it again, it breaks.

The bug may also be there if you close it yourself, switch to portrait, and then switch back.

sc_require TOO strict, rejects/ignores camel case file names

after switching from 1.0.46 to 1.4.1 I see this warning:

WARN ~ Could not find entry 'system/loader' required in sproutcore/bootstrap:source/setup_body_class_names.js

and then none of my sc_requires are found, the files are loaded anyways but not in the right order which breaks the app.

turned out to be the sc_require parser not liking camel case anymore (used to in 1.0)

SelectView 'parentMenu'

In SC 1.0 and beyond, seems that SelectView has had a bug that triggered the following error message:

TypeError: Object [object DOMWindow] has no method 'parentMenu'

This error still ails SC 1.4.2. A fix was proposed in http://goo.gl/cjSN

Inconsistencies with Nested Records

There are some problems working with nested records:

  1. When the nested record is first created, it is added to the store's changelog, which would be fine except that the store is not being updated when the nested record's status changes from READY_NEW to READY_CLEAN. Therefore, calling commitRecords() on the store causes all of your nested records to be duplicated. To see this, use store.readStatus() on the nested record, if you use nestedRecord.get('status'), then the store's status will be updated.
  2. Modifying a nested record within a nested store does not work. The nested record's _parentRecord does not get transferred over into the nested store version and therefore, the nested store parent record is never notified of any changes. Committing changes from the nested store ends up with only the nested record's status being READY_DIRTY, but the changes in the nested record don't exist in its parent record and therefore are very easily overwritten whenever the parent record updates.

IE8 chokes on Quilmes (1.5/development branch)

Hi,

IE8 will not run the latest Quilmes.

To reproduce:

Using the latest sproutcore gem (1.4 pre)

  • sc-init IETest

    cd ie_test

    mkdir frameworks

    cd frameworks

    git clone http://github.com/sproutcore/sproutcore.git

    cd sproutcore

    git checkout quilmes

    cd ../..

    sc-server -v

  • open IE8 in a Parallels instance, visit the sc-server site (in my case, http://rklancer-unibody-2.local:4020/ )

  • wait for the Welcome app to come up

  • Click around; nothing happens.

  • Open the Developer toolbar (Tools -> Developer Tools)

  • Click the 'Console' tab if it's not already selected. You should see several 'Invalid Argument' errors referencing this line from jquery.js:

    if ( set ) {
        style[ name ] = value;
    }
    

The issue appears to be that view.js is setting the 'zIndex' and 'backgroundPosition' style attributes to null using jquery, and IE8 does not tolerate a null value of these attributes

UPDATED: I fixed the issue with a "works for me" in commit 5c87a88 in branch 'better-quilmes-ie-fix' of my fork but need guidance regarding:

  1. Is this really a jquery issue? Should jquery normalize these 2 attributes?
  2. Does my change cause any other tests to fail?
  3. Should I/how can I create a failing test to demonstrate the problem?

Ensure that default external encoding of UTF-8 is always used in build tools

This issue became apparent when I attempted to run the build tools from an ant task. I believe the java VM defaults to ascii encoding and so I was get a Fatal encoding error. Wycats helped me out in irc, and i discovered "Encoding.default_external" was ASCII while running from ant but UTF-8 when running from the command line.

As I quick fix to the problem, I have added "Encoding.default_external="utf-8" to the top of my sproutcore.rb to ensure it is always used.

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.