You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardexpand all lines: static/js/sefaria/sefaria.js
+9
Original file line number
Diff line number
Diff line change
@@ -292,6 +292,15 @@ Sefaria = extend(Sefaria, {
292
292
returnoref ? oref.sectionRef : null;
293
293
294
294
},
295
+
zoomOutRef: function(ref,zoom=1){
296
+
// go up `zoom` levels in the ref's sections and toSections
297
+
// for example, if ref == "Ramban on Genesis, Introduction 2" and zoom == 1, this returns "Ramabn on Genesis, Introduction"
298
+
// if ref == "Ramban on Genesis, Introduction 2" and zoom == 2, this returns "Ramban on Genesis, Introduction" because we're only zooming out on the ref's sections/toSections
0 commit comments