úÎӦ˾      !"#$%&'()*+,-./0123456789:;<=>?@ABCDEFGH I J K L M N O P Q R S T U V W X Y Z [ \ ] ^ _ ` a b c d e f g h i j k l m n o p q r s t u v w x y z { | } ~Safe½€‚ƒ„…†None$ЪA splice that makes the CSRF token available to templates. Typically we use it by binding a splice and using the CSRF token provided by the session snaplet as follows: -("csrfToken", csrfTokenSplice $ with session ‡)Where session‘ is a lens to the session snaplet. Then you can make it available to javascript code by putting a meta tag at the top of every page like this: /<meta name="csrf-token" content="${csrfToken}">ÿBAdds a hidden _csrf input field as the first child of the bound tag. For full site protection against CSRF, you should bind this splice to the form tag, and then make sure your app checks all POST requests for the presence of this CSRF token and that the token is randomly generated and secure on a per session basis.ÿ¸Use this function to wrap your whole site with CSRF protection. Due to security considerations, the way Snap parses file uploads means that the CSRF token cannot be checked before the file uploads have been handled. This function protects your whole site except for handlers of multipart/form-data forms (forms with file uploads). To protect those handlers, you have to call handleCSRF explicitly after the file has been processed.ÉIf a request is a POST, check the CSRF token and fail with the specified handler if the check fails. If if the token is correct or if it's not a POST request, then control passes through as a no-op. A version of d that works as an imperative filter. It's a NOOP when successful, redirs to oblivion under failure.HA computation in the runtime monad that gets the CSRF protection token.HA computation in the runtime monad that gets the CSRF protection token.Lens to the session snaplet&Handler to run if the CSRF check fails'Handler to let through when successful.Lens to the session snapletHandler to run on failure'Handler to let through when successful. On failureNone;wUDiscard anything after this and return given status code to HTTP client immediately. Finish early with error code 400 Finish early with error code 404 Finish early with error code 500 Mark response as  'text/plain' Mark response as 'application/json' Mark response as 'application/javascript' }Easier debug logging into error log. First argument is a category/namespace and the second argument is anything that has a ˆ instance. AAlternate version of getParam that considers empty string Nothing7Require that a parameter is present or terminate early.gRead a parameter from request. Be sure it is readable if it's there, or else this will raise an error.xTry to read a parameter from request. Computation may fail because the param is not there, or because it can't be read.YRedirects back to the refering page. If there is no Referer header, then redirect to /.YRedirects back to the refering page. If there is no Referer header, then redirect to /.hIf the current rqURI does not have a trailing slash, then redirect to the same page with a slash added.bIf the current rqURI has a trailing slash, then redirect to the same page with no trailing slash.-Evaluates an action that returns a Maybe and %Concatenates two URL segments with a ‰› between them. To prevent double slashes, all trailing slashes are removed from the first path and all leading slashes are removed from the second path.   Soostone IncBSD3 Ozgun Ataman experimentalNoneJƒlPossible reponse types we support at the moment. Can be expanded for more use cases like JSON, CSV and XML.8Replace innerHTML of given selector with given conntent.ŠFProduce JS statement to replace a target's inner with given contents.eReplace the inner HTML element of a given selector with the contents of the rendered Heist template.OCurrently expect you to have jQuery loaded. TODO: Make this jQuery independent/The multi-mime dispatcher. It will inspect the Acceptg header and determine what type of a request this is. If AJAX, make sure to set the Accept header to 'application/javascript'.Dispatch on all response typesOClassic pattern of responding to a static HTML or an alternative AJAX request.jquery selector content blobHeist template name*jQuery selector for target element on pageIf call is HTMLIf call is AJAXNoneSã$xInitialize the flash notice system. All you have to do now is to add some flash tags in your application template. See ) for examples.%.Display an info message on next load of a page&1Display an warning message on next load of a page'0Display a success message on next load of a page(/Display an error message on next load of a page)5A splice for rendering a given flash notice dirctive.Ex:  flashtype='warning'/ Ex: flashtype='success'/*>A compiled splice for rendering a given flash notice dirctive.Ex:  flashtype='warning'/ Ex: flashtype='success'/$%&'()*$%&'()*None"#[Ù+-Transform to Nothing if field is empty string,Maybe read into target value-Read into target value.VConstructs a generalized edit form splice that looks up an ID param specified by the by2 attribute. You might use this splice as follows: <editFormSplice by="id">If you don't specify the by attribute, the default is by="id"..WFunction for generating a splice from an optional default value calculated at runtime./Function for retrieving the form default by ID.+,-.+,-.Noneed/TDemand the presence of JSON in the body assuming it is not larger than 50000 bytes.0 Demand the presence of JSON in the body with a size up to N bytes. If parsing fails for any reson, request is terminated early and a server error is returned.1DTry to parse request body as JSON with a default max size of 50000.27Parse request body into JSON or return an error string.3(Get JSON data from the given Param field4,Force the JSON value from field. Similar to 35 Set MIME to 'application/json' and write given object into ‹ body.0Maximum size in bytes2Maximum size in bytes/012345210/345Nonelº6ÿ`Wrap a handler with method override support. This means that if (and only if) the request is a POST, _method param is passed, and it is a parsable method name, it will change the request method to the supplied one. This works around some browser limitations with forms. If you use a different parameter name than _method, use handleMethodOverride'6Internal handler to call7parameter name for methodInternal handler to call6767NoneVo_:A session manager for the base;Lens to the session snapletOThe heist snaplet (not a lens), if you want splices to be added automatically.89:;<=>?@ABCDEFG89:;<=>?@ABCDEFG89: None"#NV†÷ HThe complete status of a job.P*Enumeration of the states a job can be in.U>Top-level handler that handles the job polling infrastructure.VjFunction to generate a status splice. This splice makes the following splices available to its children:lConditional splices: ifPending, ifRunning, ifNotFinished, ifFinished, ifFinishedSuccess, ifFinishedFailurevData splices: elapsedSeconds, startTime, endTime, jobState, messages, percentCompleted, amountCompleted, amountTotalŒ<JS code to do an AJAX request to updateStatus after a delay.W6Returns a bool indicating whether the job is finished.X6Returns a bool indicating whether the job is finished.Y+Calculates the percent completed as an Int.ZThe status splicesU:Name of the template to use for the updateStatus endpoint.aA CSS selector string used to substitute the contents of the AJAX template into the status page.V0Splices defined for your job status type status.ÀHandler to get the URL that should be used for requesting AJAX status updates. This must be a handler because it will usually contain some form of job ID that is only obtainable at runtime.šHandler that knows how to get the status of the job in question. This typically will require it to know how to get some sort of job ID from the request.1A function to tell whether the status is finishedŒ&The url for incremental status updatesEThe amount of time to wait before requesting the page in millisecondsHILJKMNOPRQSTUVWXYZ[UVPQRSTWXHIJKLMNOY[ZHIJKLMNOPQRSTNoneˆ Nonež„b(A list of splices offered in this moduled4Gets the value of a request parameter. Example use: rqparamname="username"/e7Assume text area contains the name of a splice as Text.„This is helpful when you pass a default value to digestive-functors by putting the name of a splice as the value of a textarea tag. ,heistLocal runTextAreas $ render "joo/index"f8Splice helper for when you're rendering a select elementgÊSearches a directory on disk and all its subdirectories for all files with names that don't begin with an underscore and end with a .js extension. It then returns script tags for each of these files.-You can use this function to create a splice: 0("staticscripts", scriptsSplice "static/js" "/")Then when you use the <staticscripts/>V tag in your templates, it will automatically include all the javascript code in the  static/js directory.h¼Check to see if the boolean flag named by the "ref" attribute is present and set to true in snaplet user config file. If so, run what's inside this splice, if not, simply omit that part.Example: 4<flag ref="beta-functions-enabled"> stuff... </flag>2This will look for an entry inside your .cfg file: beta-functions-enabled = truefA name for the select elementAn id for the select elementvalue, shown text pairs Default valueg;Path to the directory on disk holding the javascript files.8A prefix to add to the src attribute of each script tag.bcdefghdbfeghc None¸k4Gets the value of a request parameter. Example use: rqparamname="username"/lÊSearches a directory on disk and all its subdirectories for all files with names that don't begin with an underscore and end with a .js extension. It then returns script tags for each of these files.-You can use this function to create a splice: 0("staticscripts", scriptsSplice "static/js" "/")Then when you use the <staticscripts/>V tag in your templates, it will automatically include all the javascript code in the  static/js directory.mÿªSometimes in a loop you don't always want the same behavior for every item. If you have a comma separated list, you usually don't want a comma after the last item. If you have a list surrounded by parentheses, you might not want the parentheses to show up if the list is empty. Dealing with these situations can be a pain with the stock looping splices, so we've provided this helper that solves all of these problems.ÿThis function is similar to manyWithSplices, but it binds three additional splices: "prelude", "interlude", and "postlude". The children of the prelude and postlude splices only show up before the beginning of the list and after the end of the list if the list is non-empty. The children of the interlude splice are used as a separator between each list element. If the list has only one element, then the separator does not appear. These splices have this behavior regardless of where they appear in the parent tag.l<Path to the directory on disk holding the javascript files.8A prefix to add to the src attribute of each script tag.ijklmijklm NoneÇ© n A tab is a Ž0 generator upon receiving a current URL context.o(How do we decide "active" for tab state?p Current url has to match exactlyq*Only the prefix needs to match current urlr)A sub-set of the current url has to matchuCompiled splice for tabs.tCan't use tabSpliceWorker because we have to explicitly run the attributes in order to get ${} splice substitution.w(Make tabs from tab definitions. Use the x* combinator to define individual options.x%Tab item constructor to be used with w=. Just supply the given arguments here and it will create a n ready to be used in w.IIf the tab is currently active, the li tag will get a class of 'active'.ŒMake sure to provide a trailing / when indicating URLs as snap context paths contain it and active tab checks will be confused without it.w(A class to be given to the parent ul tagList of tabs in orderxTarget URL for tabA text/label for tabA list of attributes as key=valA o for this tab nopqrstuvwx tvuopqrsnwxopqrs SafeÈNyz{|}{y|z}NoneÊ ~Initialize all the b functionality in your Snap app. Currently, we don't need to keep any state and simply return ().E $%&'()*+,-./01234567nopqrstuvwxyz{|}~~ !"#$%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKKLMNOPQRSTUVWXY Z Z [ \ ] ^ _ ` a b c d e f g h i j k l m n o p q r s t u v w x y s z u x { | } ~  €  ‚ ƒ „ … † ‡ ˆ ‰ Š ‹ŒŽ‘’“”•–—˜™š˜›œžŸ  ¡¢£¤¥ ¦§+snap-extras-0.12.1.1-JcytGPkrCRc3sAFn7r8aTGSnap.Extras.CSRFSnap.Extras.CoreUtilsSnap.Extras.AjaxSnap.Extras.FlashNoticeSnap.Extras.FormUtilsSnap.Extras.JSONSnap.Extras.MethodOverrideSnap.Extras.NavTrailsSnap.Extras.PollStatus#Snap.Extras.SpliceUtils.Interpreted Snap.Extras.SpliceUtils.CompiledSnap.Extras.TabsSnap.Extras.TextUtils Snap.ExtrasPaths_snap_extrasSnap.Extras.SpliceUtils.CommonSnapExtrascsrfTokenSplice secureForm blanketCSRF handleCSRF handleCSRF' finishEarlybadReqnotFound serverError plainResponse jsonResponse jsResponseeasyLog getParam'reqParam readParam readMayParamredirectRefererredirectRefererFuncdirifyundirify maybeBadReq fromMaybeM-/- ResponseTypeHtmlAjax replaceWithreplaceWithTemplaterespondresponds htmlOrAjax$fEqResponseType$fShowResponseType$fReadResponseType$fOrdResponseTypeinitFlashNotice flashInfo flashWarning flashSuccess flashError flashSplice flashCSplice maybeTrans readMayTrans readTranseditFormSplicereqJSONreqBoundedJSONgetJSONgetBoundedJSON getJSONField reqJSONField writeJSONhandleMethodOverridehandleMethodOverride'NavTrailntSes initNavTrailsetFocus setFocus' setFocusToRefgetFocus getFocusDef redirBack redirFocus backSplice backCSplice focusSplice focusCSpliceaddNavTrailSplicesStatusstatusStartTimestatusTimestampstatusJobStatestatusMessagesstatusAmountCompletedstatusAmountTotalJobStatePendingRunningFinishedSuccessFinishedFailurejobStatusHandler statusSplice jobFinishedstatusFinishedstatusPercentCompleted statusSplices statusElapsed $fEqJobState$fShowJobState$fReadJobState$fEnumJobState $fEqStatus $fShowStatus utilSplices refererSplice paramSplice runTextAreas selectSplice scriptsSplice ifFlagSplicerefererCSplicefancyLoopSpliceTab TabActiveMode TAMExactMatchTAMPrefixMatch TAMInfixMatch TAMDontMatchinitTabs tabsCSplice tabsSplicemkTabstabshowTshowBSreadTreadBS titleCase initExtrasversion getBinDir getLibDir getDynLibDir getDataDir getLibexecDir getSysconfDirgetDataFileName#snap-1.0.0.2-2DTzxFgVOwb8mfABX0eR6USnap.Snaplet.Session csrfTokenbaseGHC.ShowShowGHC.Real/ replaceWithJs(snap-core-1.0.3.1-2AdJnsyYWETBIDxidhyLXmSnap.Internal.Http.TypesResponseupdateJS getScripts&xmlhtml-0.2.5.2-1XGqRKHjpoMBsUAvjUOFiKText.XmlHtml.CommonNode tabCSplice