aboutsummaryrefslogtreecommitdiffhomepage
path: root/client/src/app/shared/misc
diff options
context:
space:
mode:
authorChocobozzz <me@florianbigard.com>2018-02-13 14:11:05 +0100
committerChocobozzz <me@florianbigard.com>2018-02-13 14:20:46 +0100
commit0cd4344f3cf529b15308fcf3eb7d7eb07726df56 (patch)
tree276f6e8cfe72d583114d82fd5db981550a395488 /client/src/app/shared/misc
parent29c6b829446a6fb29dffc6b7b638079ce60f3771 (diff)
downloadPeerTube-0cd4344f3cf529b15308fcf3eb7d7eb07726df56.tar.gz
PeerTube-0cd4344f3cf529b15308fcf3eb7d7eb07726df56.tar.zst
PeerTube-0cd4344f3cf529b15308fcf3eb7d7eb07726df56.zip
Rewrite infinite scroll
Diffstat (limited to 'client/src/app/shared/misc')
-rw-r--r--client/src/app/shared/misc/utils.ts7
1 files changed, 6 insertions, 1 deletions
diff --git a/client/src/app/shared/misc/utils.ts b/client/src/app/shared/misc/utils.ts
index 6620ac973..e6a697098 100644
--- a/client/src/app/shared/misc/utils.ts
+++ b/client/src/app/shared/misc/utils.ts
@@ -55,6 +55,10 @@ function dateToHuman (date: string) {
55 return datePipe.transform(date, 'medium') 55 return datePipe.transform(date, 'medium')
56} 56}
57 57
58function immutableAssign <A, B> (target: A, source: B) {
59 return Object.assign({}, target, source)
60}
61
58function isInSmallView () { 62function isInSmallView () {
59 return window.innerWidth < 600 63 return window.innerWidth < 600
60} 64}
@@ -70,5 +74,6 @@ export {
70 getAbsoluteAPIUrl, 74 getAbsoluteAPIUrl,
71 dateToHuman, 75 dateToHuman,
72 isInSmallView, 76 isInSmallView,
73 isInMobileView 77 isInMobileView,
78 immutableAssign
74} 79}