Commit Graph

4770 Commits

Author SHA1 Message Date
Avital Oliver
01fd48cb88 unbreak created and destroyed callbacks
there is no DomRange available then, so don't
set firstNode and lastNode on the template instance
2013-09-18 13:51:04 -07:00
David Greenspan
665cfb269d next step in porting template-demo 2013-09-18 10:34:17 -07:00
David Greenspan
c05201b83b no-op {{#constant}} and {{#isolate}} 2013-09-18 10:33:30 -07:00
David Greenspan
af0aad1d45 created/rendered/destroyed callbacks
preserve no-op
2013-09-17 15:52:39 -07:00
David Greenspan
4658b70d7e comments 2013-09-17 15:16:03 -07:00
David Greenspan
0bf617ed47 make #with work 2013-09-17 14:32:03 -07:00
David Greenspan
4add01f934 events seem to work 2013-09-17 14:25:01 -07:00
David Greenspan
6d09d6c026 wip
TODO:
- fix "DomRange host" problem
  - maybe no renderToRange, we just put a new
    range in the same spot?
  - what about "each" reactive "content"?
    - if "content" changes, invalidates whole render
- don't "renderTo" top-level sub-components
  in renderbuffer, just build them or something
2013-09-16 20:37:50 -07:00
David Greenspan
3f176e2604 test-in-browser works! (minus events) 2013-09-16 18:02:09 -07:00
David Greenspan
61b86dbb43 comment 2013-09-16 15:12:33 -07:00
David Greenspan
1879d14df4 #each uses observe-sequence, supports arrays 2013-09-13 12:27:58 -07:00
David Greenspan
d5da9341c1 Merge branch 'observe-sequence' into shark-domrange 2013-09-13 12:06:43 -07:00
Avital Oliver
b8c8b33fff observe-changes package to be used by {{#each}} 2013-09-13 02:43:34 -07:00
David Glasser
280a9f7179 Merge branch 'pr/1407' into devel 2013-09-12 14:29:58 -07:00
Maxime Quandalle
259fb036c8 Fix syntax 2013-09-12 14:29:50 -07:00
Maxime Quandalle
c66b8e3db5 Style tweaks 2013-09-12 14:29:50 -07:00
Maxime Quandalle
d4186524b8 Support multiple extensions in _getSourceHandler 2013-09-12 14:29:50 -07:00
Maxime Quandalle
8df6553ce2 Add a literate handler in the coffeescript package
Add .coffee.md handling tests
2013-09-12 14:29:50 -07:00
David Glasser
3665b31a82 Remove backwards-compatibility implementation of pre-0.6.5
Package.register_extension API.

It didn't even actually work for producing JavaScript files (eg a
coffeescript-like package): see #1410. Package maintainers should have upgraded
to the more powerful 0.6.5 API by now anyway.
2013-09-12 13:55:15 -07:00
David Winterbottom
a174b549b9 Correct typo in install script error message 2013-09-12 12:31:54 -07:00
Andrew Wilcox
4714f892f5 Check that the argument to EJSON.parse is a string.
Some Android browser versions of JSON.parse can crash when passed null
(https://code.google.com/p/android/issues/detail?id=11973), so it's
better not to pass on a non-string argument to JSON.parse.

Thanks to @raix for raising the issue in #1401.
2013-09-12 12:13:15 -07:00
Emily Stark
00a70b7899 Update History.md for token deletion 2013-09-11 13:48:05 -07:00
Emily Stark
aaf6c8a28a Merge branch 'expire-tokens' into devel 2013-09-11 13:44:58 -07:00
Emily Stark
0bc4bc9c26 Clean up token deletion and tests. 2013-09-11 13:44:27 -07:00
Emily Stark
d9093d6cf8 Test for logging out a user's connections when deleted.
Tests are flaky, not sure why yet.
2013-09-11 13:44:14 -07:00
Emily Stark
4ebdbd9f77 On logout, disassociate connection from token before deleting token. 2013-09-11 13:44:13 -07:00
Emily Stark
dab6df0eb9 Remove DDP disconnected message.
Instead, using a friendlier error message for bad login tokens, and preferring
localStorage tokens to the result of login method in onReconnect (since
onReconnect doesn't get cleared because we don't have a disconnected message to
know when to clean it). Also tried to make tests a little cleaner.
2013-09-11 13:44:13 -07:00
Emily Stark
09ba59c50b Close users' connections when they or their tokens are deleted. 2013-09-11 13:44:13 -07:00
Emily Stark
21dd57c95d Allow DDP client to register onDisconnect callback.
accounts-base uses this to handle disconnects due to users being intentionally
logged out.
2013-09-11 13:44:13 -07:00
Emily Stark
e84f0adb78 Add test for Meteor._logoutAllOthers.
Fix bugs to make it work.
2013-09-11 13:44:13 -07:00
Emily Stark
10d49451d9 Add experimental "disconnected" DDP message.
Client uses this to unset user id when a forced logout happens.
2013-09-11 13:44:13 -07:00
Emily Stark
8621c18bc1 Add token expiration test and fix bugs so it passes.
Also make all token-expiration-related times configurable via Accounts.config.
2013-09-11 13:44:13 -07:00
Emily Stark
2ebdeb0d95 Make token expiration times configurable via Accounts.config. 2013-09-11 13:44:13 -07:00
Emily Stark
d84334a34b Make client aware of token expiration times.
accounts-password will not try to auto-login with (and will clear) a login token
that is going to expire within an hour, to try to avoid abrupt disconnects from
an expiring token. Login handlers return a new tokenExpires field to help the
client do this. Made tokenExpires a separate field on the login handlers' result
object instead of just returning the whole token (token + when fields) in the
result to avoid breaking code that assumes that login handlers return a string
as the token field. The tokenExpires field is optional, so other login handlers
that don't set it aren't broken.
2013-09-11 13:44:13 -07:00
Emily Stark
d39726d737 Store login token on livedata session.
Allows us to remove sessions from sessionsByLoginToken when they are destroyed.
2013-09-11 13:44:13 -07:00
Emily Stark
1887d6960b Expire login tokens periodically.
When a login token expires, all open connections associated with that token will
be closed. It will be up to client code to avoid trying to connect with a login
token that is set to expire soon.
2013-09-11 13:44:13 -07:00
Emily Stark
4b7f052ce0 Wait 10 seconds before closing other logged-in sessions.
Gives other tabs sharing a token with the caller time to find the new token in
localStorage. This is sort of a hack for now; one possibility for making it less
hacky is to add a DDP disconnect message to allow the server to tell clients
that they are being disconnected but can reconnect with the provided token.
2013-09-11 13:44:13 -07:00
Emily Stark
12c0d8ef5e Rename to Meteor._logoutAllOthers 2013-09-11 13:44:12 -07:00
Emily Stark
3403b31c42 Preserve the connection that called logoutAll. 2013-09-11 13:44:12 -07:00
Emily Stark
7dfff264a3 Add method that logs the user out everywhere.
Might need some UI work; currently causes confusing error message "Couldn't find
login token."
2013-09-11 13:44:12 -07:00
Emily Stark
afa8afd9a9 Keep track of open DDP connections by login token. 2013-09-11 13:44:12 -07:00
David Greenspan
3b917d8495 uncommitted change 2013-09-11 09:25:05 -07:00
David Greenspan
7d5e3821ef towards making test driver work in new world 2013-09-09 19:00:23 -07:00
David Greenspan
457938954c delete old version of DomRange 2013-09-09 18:46:09 -07:00
David Greenspan
83c0ae7873 Merge branch 'shark-tests' into shark-domrange
Conflicts:
	packages/jquery/jquery.js
	packages/ui/package.js
2013-09-09 18:45:13 -07:00
David Greenspan
296686f81e add docs, XXX and TODOs 2013-09-09 10:45:34 -07:00
Andrew Wilcox
ba34b2550b Chrome for iOS supports the appcache 2013-09-04 16:31:52 -07:00
David Greenspan
1c223b3606 test more jQuery cases 2013-09-03 20:09:25 -07:00
David Greenspan
b2696e9a7c detect jQuery remove immediately 2013-09-03 19:51:04 -07:00
David Greenspan
930700f68c IE 9 compat; isParented; beginning of isRemoved 2013-09-03 18:25:32 -07:00