diff --git a/pom.xml b/pom.xml index 960eb1cb..e9878b73 100644 --- a/pom.xml +++ b/pom.xml @@ -138,22 +138,6 @@ - - org.codehaus.enunciate - maven-enunciate-plugin - 1.26.2 - - - package - - assemble - - - ${project.basedir}/src/main/enunciate/enunciate.xml - - - - com.github.searls jasmine-maven-plugin @@ -278,9 +262,9 @@ - com.google.code.gson - gson - 2.2.2 + com.fasterxml.jackson.jaxrs + jackson-jaxrs-json-provider + 2.1.4 org.slf4j @@ -305,9 +289,9 @@ - org.codehaus.enunciate - enunciate-core-annotations - 1.26.2 + com.wordnik + swagger-jaxrs_2.9.1 + 1.2.2 diff --git a/src/main/java/com/commafeed/frontend/CommaFeedSession.java b/src/main/java/com/commafeed/frontend/CommaFeedSession.java index 80c264e0..15675b5b 100644 --- a/src/main/java/com/commafeed/frontend/CommaFeedSession.java +++ b/src/main/java/com/commafeed/frontend/CommaFeedSession.java @@ -15,9 +15,10 @@ import com.commafeed.backend.model.UserRole.Role; import com.commafeed.backend.services.UserService; import com.google.common.collect.Sets; -@SuppressWarnings("serial") public class CommaFeedSession extends AuthenticatedWebSession { + private static final long serialVersionUID = 1L; + @Inject UserService userService; diff --git a/src/main/java/com/commafeed/frontend/rest/ApiListingResource.java b/src/main/java/com/commafeed/frontend/rest/ApiListingResource.java new file mode 100644 index 00000000..5b092a29 --- /dev/null +++ b/src/main/java/com/commafeed/frontend/rest/ApiListingResource.java @@ -0,0 +1,101 @@ +package com.commafeed.frontend.rest; + +import java.util.Enumeration; + +import javax.servlet.ServletConfig; +import javax.servlet.ServletContext; +import javax.ws.rs.GET; +import javax.ws.rs.Path; +import javax.ws.rs.Produces; +import javax.ws.rs.core.Application; +import javax.ws.rs.core.Context; +import javax.ws.rs.core.HttpHeaders; +import javax.ws.rs.core.Response; +import javax.ws.rs.core.UriInfo; + +import com.commafeed.frontend.model.Entries; +import com.wordnik.swagger.annotations.Api; +import com.wordnik.swagger.annotations.ApiOperation; +import com.wordnik.swagger.core.SwaggerSpec; +import com.wordnik.swagger.jaxrs.ConfigReader; +import com.wordnik.swagger.jaxrs.JavaApiListing; + +@Path("/resources") +@Api("/resources") +@Produces({ "application/json" }) +public class ApiListingResource extends JavaApiListing { + + @Override + @GET + @ApiOperation(value = "Returns list of all available api endpoints", responseClass = "List[DocumentationEndPoint]") + public Response getAllApis(@Context final ServletConfig sc, + @Context Application app, @Context HttpHeaders headers, + @Context UriInfo uriInfo) { + + return super.getAllApis(new ServletConfigProxy(sc), app, headers, + uriInfo); + } + + public static class ServletConfigProxy implements ServletConfig { + + private ServletConfig sc; + + public ServletConfigProxy(ServletConfig sc) { + this.sc = sc; + } + + @Override + public String getServletName() { + return sc.getServletName(); + } + + @Override + public ServletContext getServletContext() { + return sc.getServletContext(); + } + + @Override + public String getInitParameter(String name) { + if ("swagger.config.reader".equals(name)) { + return CustomConfigReader.class.getName(); + } + return sc.getInitParameter(name); + } + + @Override + public Enumeration getInitParameterNames() { + return sc.getInitParameterNames(); + } + } + + public static class CustomConfigReader extends ConfigReader { + + public CustomConfigReader(ServletConfig config) { + } + + @Override + public String basePath() { + return "http://localhost:8082/commafeed/rest"; + } + + @Override + public String swaggerVersion() { + return SwaggerSpec.version(); + } + + @Override + public String apiVersion() { + return "1.0"; + } + + @Override + public String modelPackages() { + return Entries.class.getPackage().getName(); + } + + @Override + public String apiFilterClassName() { + return null; + } + } +} \ No newline at end of file diff --git a/src/main/java/com/commafeed/frontend/rest/JSONMessageBodyReaderWriter.java b/src/main/java/com/commafeed/frontend/rest/JSONMessageBodyReaderWriter.java deleted file mode 100644 index 9b43feed..00000000 --- a/src/main/java/com/commafeed/frontend/rest/JSONMessageBodyReaderWriter.java +++ /dev/null @@ -1,124 +0,0 @@ -package com.commafeed.frontend.rest; - -import java.io.BufferedInputStream; -import java.io.IOException; -import java.io.InputStream; -import java.io.InputStreamReader; -import java.io.OutputStream; -import java.io.OutputStreamWriter; -import java.lang.annotation.Annotation; -import java.lang.reflect.Type; -import java.text.SimpleDateFormat; -import java.util.Calendar; -import java.util.Date; -import java.util.Locale; -import java.util.TimeZone; - -import javax.ws.rs.Consumes; -import javax.ws.rs.Produces; -import javax.ws.rs.WebApplicationException; -import javax.ws.rs.core.HttpHeaders; -import javax.ws.rs.core.MediaType; -import javax.ws.rs.core.MultivaluedMap; -import javax.ws.rs.ext.MessageBodyReader; -import javax.ws.rs.ext.MessageBodyWriter; -import javax.ws.rs.ext.Provider; - -import org.apache.commons.lang.time.DateUtils; - -import com.commafeed.frontend.CommaFeedSession; -import com.google.gson.Gson; -import com.google.gson.GsonBuilder; -import com.google.gson.JsonElement; -import com.google.gson.JsonPrimitive; -import com.google.gson.JsonSerializationContext; -import com.google.gson.JsonSerializer; - -@Provider -@Produces({ MediaType.APPLICATION_JSON, MediaType.TEXT_PLAIN }) -@Consumes(MediaType.APPLICATION_JSON) -public class JSONMessageBodyReaderWriter implements MessageBodyWriter, - MessageBodyReader { - - private static final String UTF_8 = "UTF-8"; - - private Gson gson; - - @Override - public boolean isWriteable(Class type, Type genericType, - Annotation[] annotations, MediaType mediaType) { - return true; - } - - @Override - public boolean isReadable(Class type, Type genericType, - Annotation[] annotations, MediaType mediaType) { - return true; - } - - @Override - public long getSize(Object t, Class type, Type genericType, - Annotation[] annotations, MediaType mediaType) { - return -1; - } - - @Override - public void writeTo(Object t, Class type, Type genericType, - Annotation[] annotations, MediaType mediaType, - MultivaluedMap httpHeaders, - OutputStream entityStream) throws IOException, - WebApplicationException { - httpHeaders.putSingle(HttpHeaders.CONTENT_TYPE, mediaType.toString() - + ";charset=" + UTF_8); - httpHeaders.putSingle(HttpHeaders.CACHE_CONTROL, "no-cache"); - httpHeaders.putSingle("Pragma", "no-cache"); - if (type == String.class) { - entityStream.write(t.toString().getBytes(UTF_8)); - } else { - OutputStreamWriter writer = new OutputStreamWriter(entityStream, - UTF_8); - getGson().toJson(t, type, writer); - writer.flush(); - } - } - - @Override - public Object readFrom(Class type, Type genericType, - Annotation[] annotations, MediaType mediaType, - MultivaluedMap httpHeaders, InputStream entityStream) - throws IOException, WebApplicationException { - InputStreamReader reader = new InputStreamReader( - new BufferedInputStream(entityStream), UTF_8); - return getGson().fromJson(reader, type); - } - - private Gson getGson() { - if (gson == null) { - gson = new GsonBuilder().registerTypeAdapter(Date.class, - new DateSerializer()).create(); - } - return gson; - } - - private static class DateSerializer implements JsonSerializer { - - private static final String DAY_FORMAT = "yyyy-MM-dd"; - private static final String TIME_FORMAT = "HH:mm"; - - public JsonElement serialize(Date src, Type typeOfSrc, - JsonSerializationContext context) { - Date now = Calendar.getInstance().getTime(); - String format = DateUtils.isSameDay(now, src) ? TIME_FORMAT - : DAY_FORMAT; - - Locale locale = CommaFeedSession.get().getLocale(); - Calendar calendar = Calendar.getInstance(locale); - TimeZone timeZone = calendar.getTimeZone(); - SimpleDateFormat dateFormat = new SimpleDateFormat(format); - dateFormat.setTimeZone(timeZone); - - return new JsonPrimitive(dateFormat.format(src)); - } - } - -} diff --git a/src/main/java/com/commafeed/frontend/rest/RESTApplication.java b/src/main/java/com/commafeed/frontend/rest/RESTApplication.java index 70318355..a74b9657 100644 --- a/src/main/java/com/commafeed/frontend/rest/RESTApplication.java +++ b/src/main/java/com/commafeed/frontend/rest/RESTApplication.java @@ -11,15 +11,22 @@ import com.commafeed.frontend.rest.resources.EntriesREST; import com.commafeed.frontend.rest.resources.SessionREST; import com.commafeed.frontend.rest.resources.SettingsREST; import com.commafeed.frontend.rest.resources.SubscriptionsREST; +import com.fasterxml.jackson.jaxrs.json.JacksonJsonProvider; import com.google.common.collect.Sets; +import com.wordnik.swagger.jaxrs.JaxrsApiReader; @ApplicationPath("/rest") public class RESTApplication extends Application { + + static { + JaxrsApiReader.setFormatString(""); + } @Override public Set> getClasses() { Set> set = Sets.newHashSet(); - set.add(JSONMessageBodyReaderWriter.class); + set.add(ApiListingResource.class); + set.add(JacksonJsonProvider.class); set.add(SubscriptionsREST.class); set.add(EntriesREST.class); diff --git a/src/main/java/com/commafeed/frontend/rest/resources/AbstractREST.java b/src/main/java/com/commafeed/frontend/rest/resources/AbstractREST.java index 2ba774ce..99d38de6 100644 --- a/src/main/java/com/commafeed/frontend/rest/resources/AbstractREST.java +++ b/src/main/java/com/commafeed/frontend/rest/resources/AbstractREST.java @@ -6,15 +6,19 @@ import javax.annotation.PostConstruct; import javax.inject.Inject; import javax.interceptor.AroundInvoke; import javax.interceptor.InvocationContext; +import javax.servlet.ServletConfig; import javax.servlet.http.HttpServletRequest; import javax.servlet.http.HttpServletResponse; import javax.ws.rs.Consumes; +import javax.ws.rs.GET; import javax.ws.rs.Produces; import javax.ws.rs.WebApplicationException; import javax.ws.rs.core.Context; +import javax.ws.rs.core.HttpHeaders; import javax.ws.rs.core.MediaType; import javax.ws.rs.core.Response; import javax.ws.rs.core.Response.Status; +import javax.ws.rs.core.UriInfo; import org.apache.wicket.ThreadContext; import org.apache.wicket.authentication.IAuthenticationStrategy; @@ -41,11 +45,14 @@ import com.commafeed.backend.services.UserService; import com.commafeed.frontend.CommaFeedApplication; import com.commafeed.frontend.CommaFeedSession; import com.commafeed.frontend.SecurityCheck; +import com.commafeed.frontend.rest.ApiListingResource.ServletConfigProxy; +import com.wordnik.swagger.annotations.ApiOperation; +import com.wordnik.swagger.jaxrs.JavaHelp; @Produces(MediaType.APPLICATION_JSON) @Consumes(MediaType.APPLICATION_JSON) @SecurityCheck(Role.USER) -public abstract class AbstractREST { +public abstract class AbstractREST extends JavaHelp { @Context HttpServletRequest request; @@ -126,7 +133,7 @@ public abstract class AbstractREST { .entity("You need to be authenticated to do this.").build()); } - boolean allowed = false; + boolean allowed = true; Method method = context.getMethod(); if (method.isAnnotationPresent(SecurityCheck.class)) { @@ -153,4 +160,12 @@ public abstract class AbstractREST { return authorized; } + @Override + @GET + @ApiOperation(value = "Returns information about API parameters", responseClass = "com.wordnik.swagger.core.Documentation") + public Response getHelp(@Context ServletConfig sc, + @Context HttpHeaders headers, @Context UriInfo uriInfo) { + return super.getHelp(new ServletConfigProxy(sc), headers, uriInfo); + } + } diff --git a/src/main/java/com/commafeed/frontend/rest/resources/AdminSettingsREST.java b/src/main/java/com/commafeed/frontend/rest/resources/AdminSettingsREST.java index c7e82271..4bbaf4f8 100644 --- a/src/main/java/com/commafeed/frontend/rest/resources/AdminSettingsREST.java +++ b/src/main/java/com/commafeed/frontend/rest/resources/AdminSettingsREST.java @@ -5,8 +5,6 @@ import javax.ws.rs.GET; import javax.ws.rs.POST; import javax.ws.rs.Path; -import org.codehaus.enunciate.doc.DocumentationGroup; - import com.commafeed.backend.model.ApplicationSettings; import com.commafeed.backend.model.UserRole.Role; import com.commafeed.backend.services.ApplicationSettingsService; @@ -14,7 +12,6 @@ import com.commafeed.frontend.SecurityCheck; @SecurityCheck(Role.ADMIN) @Path("admin/settings") -@DocumentationGroup("Application Settings") public class AdminSettingsREST { @Inject diff --git a/src/main/java/com/commafeed/frontend/rest/resources/AdminUsersREST.java b/src/main/java/com/commafeed/frontend/rest/resources/AdminUsersREST.java index cc7ea9ad..f8dcf685 100644 --- a/src/main/java/com/commafeed/frontend/rest/resources/AdminUsersREST.java +++ b/src/main/java/com/commafeed/frontend/rest/resources/AdminUsersREST.java @@ -12,7 +12,6 @@ import javax.ws.rs.core.Response; import javax.ws.rs.core.Response.Status; import org.apache.commons.lang.StringUtils; -import org.codehaus.enunciate.doc.DocumentationGroup; import com.commafeed.backend.StartupBean; import com.commafeed.backend.model.User; @@ -27,7 +26,6 @@ import com.google.common.collect.Sets; @SecurityCheck(Role.ADMIN) @Path("admin/users") -@DocumentationGroup("User Management") public class AdminUsersREST extends AbstractREST { @Path("save") diff --git a/src/main/java/com/commafeed/frontend/rest/resources/EntriesREST.java b/src/main/java/com/commafeed/frontend/rest/resources/EntriesREST.java index e3a66df1..becd15c2 100644 --- a/src/main/java/com/commafeed/frontend/rest/resources/EntriesREST.java +++ b/src/main/java/com/commafeed/frontend/rest/resources/EntriesREST.java @@ -13,7 +13,6 @@ import javax.ws.rs.core.Response; import javax.ws.rs.core.Response.Status; import org.apache.commons.lang.StringUtils; -import org.codehaus.enunciate.doc.DocumentationGroup; import com.commafeed.backend.model.FeedCategory; import com.commafeed.backend.model.FeedEntry; @@ -24,9 +23,12 @@ import com.commafeed.frontend.model.Entries; import com.commafeed.frontend.model.Entry; import com.google.common.base.Preconditions; import com.google.common.collect.Lists; +import com.wordnik.swagger.annotations.Api; +import com.wordnik.swagger.annotations.ApiOperation; +import com.wordnik.swagger.annotations.ApiParam; -@Path("entries") -@DocumentationGroup("Entries") +@Path("/entries/") +@Api(value = "/entries", description = "Operations about entries") public class EntriesREST extends AbstractREST { public static final String ALL = "all"; @@ -39,9 +41,11 @@ public class EntriesREST extends AbstractREST { all, unread; } - @Path("get") + @Path("/get") @GET - public Entries getEntries(@QueryParam("type") Type type, + @ApiOperation(value = "Find entry by ID", notes = "Add extra notes here", responseClass = "com.commafeed.frontend.model.Entries") + public Entries getEntries( + @ApiParam(value = "ID of entry that needs to be fetched", allowableValues = "range[1,5]", required = true) @QueryParam("type") Type type, @QueryParam("id") String id, @QueryParam("readType") ReadType readType, @DefaultValue("0") @QueryParam("offset") int offset, diff --git a/src/main/java/com/commafeed/frontend/rest/resources/SessionREST.java b/src/main/java/com/commafeed/frontend/rest/resources/SessionREST.java index 9a823fb9..1d8d1921 100644 --- a/src/main/java/com/commafeed/frontend/rest/resources/SessionREST.java +++ b/src/main/java/com/commafeed/frontend/rest/resources/SessionREST.java @@ -6,7 +6,6 @@ import javax.ws.rs.Path; import javax.ws.rs.core.Response; import org.apache.commons.lang.StringUtils; -import org.codehaus.enunciate.doc.DocumentationGroup; import com.commafeed.backend.model.User; import com.commafeed.backend.model.UserRole; @@ -15,7 +14,6 @@ import com.commafeed.frontend.model.ProfileModificationRequest; import com.commafeed.frontend.model.UserModel; @Path("session") -@DocumentationGroup("User settings") public class SessionREST extends AbstractREST { @Path("get") diff --git a/src/main/java/com/commafeed/frontend/rest/resources/SettingsREST.java b/src/main/java/com/commafeed/frontend/rest/resources/SettingsREST.java index b3146127..aa2a7931 100644 --- a/src/main/java/com/commafeed/frontend/rest/resources/SettingsREST.java +++ b/src/main/java/com/commafeed/frontend/rest/resources/SettingsREST.java @@ -6,8 +6,6 @@ import javax.ws.rs.Path; import javax.ws.rs.core.Response; import javax.ws.rs.core.Response.Status; -import org.codehaus.enunciate.doc.DocumentationGroup; - import com.commafeed.backend.model.UserSettings; import com.commafeed.backend.model.UserSettings.ReadingMode; import com.commafeed.backend.model.UserSettings.ReadingOrder; @@ -15,7 +13,6 @@ import com.commafeed.frontend.model.Settings; import com.google.common.base.Preconditions; @Path("settings") -@DocumentationGroup("User settings") public class SettingsREST extends AbstractREST { @Path("get") diff --git a/src/main/java/com/commafeed/frontend/rest/resources/SubscriptionsREST.java b/src/main/java/com/commafeed/frontend/rest/resources/SubscriptionsREST.java index 000de308..5cbc8842 100644 --- a/src/main/java/com/commafeed/frontend/rest/resources/SubscriptionsREST.java +++ b/src/main/java/com/commafeed/frontend/rest/resources/SubscriptionsREST.java @@ -21,7 +21,6 @@ import org.apache.commons.fileupload.disk.DiskFileItemFactory; import org.apache.commons.fileupload.servlet.ServletFileUpload; import org.apache.commons.io.IOUtils; import org.apache.commons.lang.ObjectUtils; -import org.codehaus.enunciate.doc.DocumentationGroup; import com.commafeed.backend.model.Feed; import com.commafeed.backend.model.FeedCategory; @@ -33,7 +32,6 @@ import com.commafeed.frontend.rest.resources.EntriesREST.Type; import com.google.common.base.Preconditions; @Path("subscriptions") -@DocumentationGroup("Subscriptions") public class SubscriptionsREST extends AbstractREST { @GET diff --git a/src/main/webapp/WEB-INF/web.xml b/src/main/webapp/WEB-INF/web.xml index a6b66b08..b432d99b 100644 --- a/src/main/webapp/WEB-INF/web.xml +++ b/src/main/webapp/WEB-INF/web.xml @@ -11,8 +11,8 @@ com.commafeed.frontend.CommaFeedApplication - configuration - deployment + configuration + deployment diff --git a/src/main/webapp/swagger/css/hightlight.default.css b/src/main/webapp/swagger/css/hightlight.default.css new file mode 100644 index 00000000..e417fc17 --- /dev/null +++ b/src/main/webapp/swagger/css/hightlight.default.css @@ -0,0 +1,135 @@ +/* + +Original style from softwaremaniacs.org (c) Ivan Sagalaev + +*/ + +pre code { + display: block; padding: 0.5em; + background: #F0F0F0; +} + +pre code, +pre .subst, +pre .tag .title, +pre .lisp .title, +pre .clojure .built_in, +pre .nginx .title { + color: black; +} + +pre .string, +pre .title, +pre .constant, +pre .parent, +pre .tag .value, +pre .rules .value, +pre .rules .value .number, +pre .preprocessor, +pre .ruby .symbol, +pre .ruby .symbol .string, +pre .aggregate, +pre .template_tag, +pre .django .variable, +pre .smalltalk .class, +pre .addition, +pre .flow, +pre .stream, +pre .bash .variable, +pre .apache .tag, +pre .apache .cbracket, +pre .tex .command, +pre .tex .special, +pre .erlang_repl .function_or_atom, +pre .markdown .header { + color: #800; +} + +pre .comment, +pre .annotation, +pre .template_comment, +pre .diff .header, +pre .chunk, +pre .markdown .blockquote { + color: #888; +} + +pre .number, +pre .date, +pre .regexp, +pre .literal, +pre .smalltalk .symbol, +pre .smalltalk .char, +pre .go .constant, +pre .change, +pre .markdown .bullet, +pre .markdown .link_url { + color: #080; +} + +pre .label, +pre .javadoc, +pre .ruby .string, +pre .decorator, +pre .filter .argument, +pre .localvars, +pre .array, +pre .attr_selector, +pre .important, +pre .pseudo, +pre .pi, +pre .doctype, +pre .deletion, +pre .envvar, +pre .shebang, +pre .apache .sqbracket, +pre .nginx .built_in, +pre .tex .formula, +pre .erlang_repl .reserved, +pre .prompt, +pre .markdown .link_label, +pre .vhdl .attribute, +pre .clojure .attribute, +pre .coffeescript .property { + color: #88F +} + +pre .keyword, +pre .id, +pre .phpdoc, +pre .title, +pre .built_in, +pre .aggregate, +pre .css .tag, +pre .javadoctag, +pre .phpdoc, +pre .yardoctag, +pre .smalltalk .class, +pre .winutils, +pre .bash .variable, +pre .apache .tag, +pre .go .typename, +pre .tex .command, +pre .markdown .strong, +pre .request, +pre .status { + font-weight: bold; +} + +pre .markdown .emphasis { + font-style: italic; +} + +pre .nginx .built_in { + font-weight: normal; +} + +pre .coffeescript .javascript, +pre .javascript .xml, +pre .tex .formula, +pre .xml .javascript, +pre .xml .vbscript, +pre .xml .css, +pre .xml .cdata { + opacity: 0.5; +} diff --git a/src/main/webapp/swagger/css/screen.css b/src/main/webapp/swagger/css/screen.css new file mode 100644 index 00000000..06050e76 --- /dev/null +++ b/src/main/webapp/swagger/css/screen.css @@ -0,0 +1,1759 @@ +html, body, div, span, applet, object, iframe, +h1, h2, h3, h4, h5, h6, p, blockquote, pre, +a, abbr, acronym, address, big, cite, code, +del, dfn, em, img, ins, kbd, q, s, samp, +small, strike, strong, sub, sup, tt, var, +b, u, i, center, +dl, dt, dd, ol, ul, li, +fieldset, form, label, legend, +table, caption, tbody, tfoot, thead, tr, th, td, +article, aside, canvas, details, embed, +figure, figcaption, footer, header, hgroup, +menu, nav, output, ruby, section, summary, +time, mark, audio, video { + margin: 0; + padding: 0; + border: 0; + font-size: 100%; + font: inherit; + vertical-align: baseline; +} + +body { + line-height: 1; +} + +ol, ul { + list-style: none; +} + +table { + border-collapse: collapse; + border-spacing: 0; +} + +caption, th, td { + text-align: left; + font-weight: normal; + vertical-align: middle; +} + +q, blockquote { + quotes: none; +} + +q:before, q:after, blockquote:before, blockquote:after { + content: ""; + content: none; +} + +a img { + border: none; +} + +article, aside, details, figcaption, figure, footer, header, hgroup, menu, nav, section, summary { + display: block; +} + +h1 a, h2 a, h3 a, h4 a, h5 a, h6 a { + text-decoration: none; +} + +h1 a:hover, h2 a:hover, h3 a:hover, h4 a:hover, h5 a:hover, h6 a:hover { + text-decoration: underline; +} + +h1 span.divider, h2 span.divider, h3 span.divider, h4 span.divider, h5 span.divider, h6 span.divider { + color: #aaaaaa; +} + +h1 { + color: black; + font-size: 1.5em; + line-height: 1.3em; + padding: 10px 0 10px 0; + font-family: "Droid Sans", sans-serif; + font-weight: bold; +} + +h2 { + color: black; + font-size: 1.3em; + padding: 10px 0 10px 0; +} + +h2 a { + color: black; +} + +h2 span.sub { + font-size: 0.7em; + color: #999999; + font-style: italic; +} + +h2 span.sub a { + color: #777777; +} + +h3 { + color: black; + font-size: 1.1em; + padding: 10px 0 10px 0; +} + +.heading_with_menu { + float: none; + clear: both; + overflow: hidden; + display: block; +} + +.heading_with_menu h1, .heading_with_menu h2, .heading_with_menu h3, .heading_with_menu h4, .heading_with_menu h5, .heading_with_menu h6 { + display: block; + clear: none; + float: left; + -moz-box-sizing: border-box; + -webkit-box-sizing: border-box; + -ms-box-sizing: border-box; + box-sizing: border-box; + width: 60%; +} + +.heading_with_menu ul { + display: block; + clear: none; + float: right; + -moz-box-sizing: border-box; + -webkit-box-sizing: border-box; + -ms-box-sizing: border-box; + box-sizing: border-box; + margin-top: 10px; +} + +input.parameter { + width: 300px; + border: 1px solid #aaa; +} + +.body-textarea { + width: 300px; + height: 100px; + border: 1px solid #aaa; +} + +p { + line-height: 1.4em; + padding: 0 0 10px; + color: #333333; +} + +ol { + margin: 0px 0 10px; + padding: 0 0 0 18px; + list-style-type: decimal; +} + +ol li { + padding: 5px 0px; + font-size: 0.9em; + color: #333333; +} + +.markdown h3 { + color: #547f00; +} + +.markdown h4 { + color: #666666; +} + +.markdown pre { + font-family: "Anonymous Pro", "Menlo", "Consolas", "Bitstream Vera Sans Mono", "Courier New", monospace; + background-color: #fcf6db; + border: 1px solid #e5e0c6; + padding: 10px; + margin: 0 0 10px 0; +} + +.markdown pre code { + line-height: 1.6em; +} + +.markdown p code, .markdown li code { + font-family: "Anonymous Pro", "Menlo", "Consolas", "Bitstream Vera Sans Mono", "Courier New", monospace; + background-color: #f0f0f0; + color: black; + padding: 1px 3px; +} + +.markdown ol, .markdown ul { + font-family: "Droid Sans", sans-serif; + margin: 5px 0 10px; + padding: 0 0 0 18px; + list-style-type: disc; +} + +.markdown ol li, .markdown ul li { + padding: 3px 0px; + line-height: 1.4em; + color: #333333; +} + +div.gist { + margin: 20px 0 25px 0 !important; +} + +p.big, div.big p { + font-size: 1em; + margin-bottom: 10px; +} + +span.weak { + color: #666666; +} + +span.blank, span.empty { + color: #888888; + font-style: italic; +} + +a { + color: #547f00; +} + +b, strong { + font-family: "Droid Sans", sans-serif; + font-weight: bold; +} + +.code { + font-family: "Anonymous Pro", "Menlo", "Consolas", "Bitstream Vera Sans Mono", "Courier New", monospace; +} + +pre { + font-family: "Anonymous Pro", "Menlo", "Consolas", "Bitstream Vera Sans Mono", "Courier New", monospace; + background-color: #fcf6db; + border: 1px solid #e5e0c6; + padding: 10px; +} + +pre code { + line-height: 1.6em; +} + +.required { + font-weight: bold; +} + +table.fullwidth { + width: 100%; +} + +table thead tr th { + padding: 5px; + font-size: 0.9em; + color: #666666; + border-bottom: 1px solid #999999; +} + +table tbody tr.offset { + background-color: #f5f5f5; +} + +table tbody tr td { + padding: 6px; + font-size: 0.9em; + border-bottom: 1px solid #cccccc; + vertical-align: top; + line-height: 1.3em; +} + +table tbody tr:last-child td { + border-bottom: none; +} + +table tbody tr.offset { + background-color: #f0f0f0; +} + +form.form_box { + background-color: #ebf3f9; + border: 1px solid #c3d9ec; + padding: 10px; +} + +form.form_box label { + color: #0f6ab4 !important; +} + +form.form_box input[type=submit] { + display: block; + padding: 10px; +} + +form.form_box p { + font-size: 0.9em; + padding: 0 0 15px; + color: #7e7b6d; +} + +form.form_box p a { + color: #646257; +} + +form.form_box p strong { + color: black; +} + +form.form_box p.weak { + font-size: 0.8em; +} + +form.formtastic fieldset.inputs ol li p.inline-hints { + margin-left: 0; + font-style: italic; + font-size: 0.9em; + margin: 0; +} + +form.formtastic fieldset.inputs ol li label { + display: block; + clear: both; + width: auto; + padding: 0 0 3px; + color: #666666; +} + +form.formtastic fieldset.inputs ol li label abbr { + padding-left: 3px; + color: #888888; +} + +form.formtastic fieldset.inputs ol li.required label { + color: black; +} + +form.formtastic fieldset.inputs ol li.string input, form.formtastic fieldset.inputs ol li.url input, form.formtastic fieldset.inputs ol li.numeric input { + display: block; + padding: 4px; + width: auto; + clear: both; +} + +form.formtastic fieldset.inputs ol li.string input.title, form.formtastic fieldset.inputs ol li.url input.title, form.formtastic fieldset.inputs ol li.numeric input.title { + font-size: 1.3em; +} + +form.formtastic fieldset.inputs ol li.text textarea { + font-family: "Droid Sans", sans-serif; + height: 250px; + padding: 4px; + display: block; + clear: both; +} + +form.formtastic fieldset.inputs ol li.select select { + display: block; + clear: both; +} + +form.formtastic fieldset.inputs ol li.boolean { + float: none; + clear: both; + overflow: hidden; + display: block; +} + +form.formtastic fieldset.inputs ol li.boolean input { + display: block; + float: left; + clear: none; + margin: 0 5px 0 0; +} + +form.formtastic fieldset.inputs ol li.boolean label { + display: block; + float: left; + clear: none; + margin: 0; + padding: 0; +} + +form.formtastic fieldset.buttons { + margin: 0; + padding: 0; +} + +form.fullwidth ol li.string input, form.fullwidth ol li.url input, form.fullwidth ol li.text textarea, form.fullwidth ol li.numeric input { + width: 500px !important; +} + +body { + font-family: "Droid Sans", sans-serif; +} + +body #content_message { + margin: 10px 15px; + font-style: italic; + color: #999999; +} + +body #header { + background-color: #89bf04; + padding: 14px; +} + +body #header a#logo { + font-size: 1.5em; + font-weight: bold; + text-decoration: none; + background: transparent url(../images/logo_small.png) no-repeat left center; + padding: 20px 0 20px 40px; + color: white; +} + +body #header form#api_selector { + display: block; + clear: none; + float: right; +} + +body #header form#api_selector .input { + display: block; + clear: none; + float: left; + margin: 0 10px 0 0; +} + +body #header form#api_selector .input input { + font-size: 0.9em; + padding: 3px; + margin: 0; +} + +body #header form#api_selector .input input#input_baseUrl { + width: 400px; +} + +body #header form#api_selector .input input#input_apiKey { + width: 200px; +} + +body #header form#api_selector .input a#explore { + display: block; + text-decoration: none; + font-weight: bold; + padding: 6px 8px; + font-size: 0.9em; + color: white; + background-color: #547f00; + -moz-border-radius: 4px; + -webkit-border-radius: 4px; + -o-border-radius: 4px; + -ms-border-radius: 4px; + -khtml-border-radius: 4px; + border-radius: 4px; +} + +body #header form#api_selector .input a#explore:hover { + background-color: #547f00; +} + +body p#colophon { + margin: 0 15px 40px 15px; + padding: 10px 0; + font-size: 0.8em; + border-top: 1px solid #dddddd; + font-family: "Droid Sans", sans-serif; + color: #999999; + font-style: italic; +} + +body p#colophon a { + text-decoration: none; + color: #547f00; +} + +body ul#resources { + font-family: "Droid Sans", sans-serif; + font-size: 0.9em; +} + +body ul#resources li.resource { + border-bottom: 1px solid #dddddd; +} + +body ul#resources li.resource:last-child { + border-bottom: none; +} + +body ul#resources li.resource div.heading { + border: 1px solid transparent; + float: none; + clear: both; + overflow: hidden; + display: block; +} + +body ul#resources li.resource div.heading h2 { + color: #999999; + padding-left: 0; + display: block; + clear: none; + float: left; + font-family: "Droid Sans", sans-serif; + font-weight: bold; +} + +body ul#resources li.resource div.heading h2 a { + color: #999999; +} + +body ul#resources li.resource div.heading h2 a:hover { + color: black; +} + +body ul#resources li.resource div.heading ul.options { + overflow: hidden; + padding: 0; + display: block; + clear: none; + float: right; + margin: 14px 10px 0 0; +} + +body ul#resources li.resource div.heading ul.options li { + float: left; + clear: none; + margin: 0; + padding: 2px 10px; + border-right: 1px solid #dddddd; +} + +body ul#resources li.resource div.heading ul.options li:first-child, body ul#resources li.resource div.heading ul.options li.first { + padding-left: 0; +} + +body ul#resources li.resource div.heading ul.options li:last-child, body ul#resources li.resource div.heading ul.options li.last { + padding-right: 0; + border-right: none; +} + +body ul#resources li.resource div.heading ul.options li { + color: #666666; + font-size: 0.9em; +} + +body ul#resources li.resource div.heading ul.options li a { + color: #aaaaaa; + text-decoration: none; +} + +body ul#resources li.resource div.heading ul.options li a:hover { + text-decoration: underline; + color: black; +} + +body ul#resources li.resource:hover div.heading h2 a, body ul#resources li.resource.active div.heading h2 a { + color: black; +} + +body ul#resources li.resource:hover div.heading ul.options li a, body ul#resources li.resource.active div.heading ul.options li a { + color: #555555; +} + +body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.get { + float: none; + clear: both; + overflow: hidden; + display: block; + margin: 0 0 10px; + padding: 0; +} + +body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.get div.heading { + float: none; + clear: both; + overflow: hidden; + display: block; + margin: 0; + padding: 0; + background-color: #e7f0f7; + border: 1px solid #c3d9ec; +} + +body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.get div.heading h3 { + display: block; + clear: none; + float: left; + width: auto; + margin: 0; + padding: 0; + line-height: 1.1em; + color: black; +} + +body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.get div.heading h3 span { + margin: 0; + padding: 0; +} + +body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.get div.heading h3 span.http_method a { + text-transform: uppercase; + background-color: #0f6ab4; + text-decoration: none; + color: white; + display: inline-block; + width: 50px; + font-size: 0.7em; + text-align: center; + padding: 7px 0 4px 0; + -moz-border-radius: 2px; + -webkit-border-radius: 2px; + -o-border-radius: 2px; + -ms-border-radius: 2px; + -khtml-border-radius: 2px; + border-radius: 2px; +} + +body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.get div.heading h3 span.path { + padding-left: 10px; +} + +body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.get div.heading h3 span.path a { + color: black; + text-decoration: none; +} + +body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.get div.heading h3 span.path a:hover { + text-decoration: underline; +} + +body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.get div.heading ul.options { + overflow: hidden; + padding: 0; + display: block; + clear: none; + float: right; + margin: 6px 10px 0 0; +} + +body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.get div.heading ul.options li { + float: left; + clear: none; + margin: 0; + padding: 2px 10px; + border-right: 1px solid #dddddd; +} + +body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.get div.heading ul.options li:first-child, body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.get div.heading ul.options li.first { + padding-left: 0; +} + +body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.get div.heading ul.options li:last-child, body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.get div.heading ul.options li.last { + padding-right: 0; + border-right: none; +} + +body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.get div.heading ul.options li { + border-right-color: #c3d9ec; + color: #0f6ab4; + font-size: 0.9em; +} + +body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.get div.heading ul.options li a { + color: #0f6ab4; + text-decoration: none; +} + +body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.get div.heading ul.options li a:hover, body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.get div.heading ul.options li a:active, body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.get div.heading ul.options li a.active { + text-decoration: underline; +} + +body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.get div.content { + background-color: #ebf3f9; + border: 1px solid #c3d9ec; + border-top: none; + padding: 10px; + -moz-border-radius-bottomleft: 6px; + -webkit-border-bottom-left-radius: 6px; + -o-border-bottom-left-radius: 6px; + -ms-border-bottom-left-radius: 6px; + -khtml-border-bottom-left-radius: 6px; + border-bottom-left-radius: 6px; + -moz-border-radius-bottomright: 6px; + -webkit-border-bottom-right-radius: 6px; + -o-border-bottom-right-radius: 6px; + -ms-border-bottom-right-radius: 6px; + -khtml-border-bottom-right-radius: 6px; + border-bottom-right-radius: 6px; + margin: 0 0 20px; +} + +body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.get div.content h4 { + color: #0f6ab4; + font-size: 1.1em; + margin: 0; + padding: 15px 0 5px; +} + +body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.get div.content form input[type='text'].error { + outline: 2px solid black; + outline-color: #cc0000; +} + +body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.get div.content div.sandbox_header { + float: none; + clear: both; + overflow: hidden; + display: block; +} + +body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.get div.content div.sandbox_header input.submit { + display: block; + clear: none; + float: left; + padding: 6px 8px; +} + +body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.get div.content div.sandbox_header img { + display: block; + clear: none; + float: right; +} + +body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.get div.content div.sandbox_header a { + padding: 4px 0 0 10px; + color: #6fa5d2; + display: inline-block; + font-size: 0.9em; +} + +body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.get div.content div.response div.block pre { + font-family: "Anonymous Pro", "Menlo", "Consolas", "Bitstream Vera Sans Mono", "Courier New", monospace; + padding: 10px; + font-size: 0.9em; + max-height: 400px; + overflow-y: auto; +} + +body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.post { + float: none; + clear: both; + overflow: hidden; + display: block; + margin: 0 0 10px; + padding: 0; +} + +body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.post div.heading { + float: none; + clear: both; + overflow: hidden; + display: block; + margin: 0; + padding: 0; + background-color: #e7f6ec; + border: 1px solid #c3e8d1; +} + +body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.post div.heading h3 { + display: block; + clear: none; + float: left; + width: auto; + margin: 0; + padding: 0; + line-height: 1.1em; + color: black; +} + +body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.post div.heading h3 span { + margin: 0; + padding: 0; +} + +body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.post div.heading h3 span.http_method a { + text-transform: uppercase; + background-color: #10a54a; + text-decoration: none; + color: white; + display: inline-block; + width: 50px; + font-size: 0.7em; + text-align: center; + padding: 7px 0 4px 0; + -moz-border-radius: 2px; + -webkit-border-radius: 2px; + -o-border-radius: 2px; + -ms-border-radius: 2px; + -khtml-border-radius: 2px; + border-radius: 2px; +} + +body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.post div.heading h3 span.path { + padding-left: 10px; +} + +body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.post div.heading h3 span.path a { + color: black; + text-decoration: none; +} + +body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.post div.heading h3 span.path a:hover { + text-decoration: underline; +} + +body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.post div.heading ul.options { + overflow: hidden; + padding: 0; + display: block; + clear: none; + float: right; + margin: 6px 10px 0 0; +} + +body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.post div.heading ul.options li { + float: left; + clear: none; + margin: 0; + padding: 2px 10px; + border-right: 1px solid #dddddd; +} + +body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.post div.heading ul.options li:first-child, body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.post div.heading ul.options li.first { + padding-left: 0; +} + +body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.post div.heading ul.options li:last-child, body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.post div.heading ul.options li.last { + padding-right: 0; + border-right: none; +} + +body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.post div.heading ul.options li { + border-right-color: #c3e8d1; + color: #10a54a; + font-size: 0.9em; +} + +body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.post div.heading ul.options li a { + color: #10a54a; + text-decoration: none; +} + +body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.post div.heading ul.options li a:hover, body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.post div.heading ul.options li a:active, body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.post div.heading ul.options li a.active { + text-decoration: underline; +} + +body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.post div.content { + background-color: #ebf7f0; + border: 1px solid #c3e8d1; + border-top: none; + padding: 10px; + -moz-border-radius-bottomleft: 6px; + -webkit-border-bottom-left-radius: 6px; + -o-border-bottom-left-radius: 6px; + -ms-border-bottom-left-radius: 6px; + -khtml-border-bottom-left-radius: 6px; + border-bottom-left-radius: 6px; + -moz-border-radius-bottomright: 6px; + -webkit-border-bottom-right-radius: 6px; + -o-border-bottom-right-radius: 6px; + -ms-border-bottom-right-radius: 6px; + -khtml-border-bottom-right-radius: 6px; + border-bottom-right-radius: 6px; + margin: 0 0 20px; +} + +body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.post div.content h4 { + color: #10a54a; + font-size: 1.1em; + margin: 0; + padding: 15px 0 5px; +} + +body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.post div.content form input[type='text'].error { + outline: 2px solid black; + outline-color: #cc0000; +} + +body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.post div.content div.sandbox_header { + float: none; + clear: both; + overflow: hidden; + display: block; +} + +body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.post div.content div.sandbox_header input.submit { + display: block; + clear: none; + float: left; + padding: 6px 8px; +} + +body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.post div.content div.sandbox_header img { + display: block; + clear: none; + float: right; +} + +body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.post div.content div.sandbox_header a { + padding: 4px 0 0 10px; + color: #6fc992; + display: inline-block; + font-size: 0.9em; +} + +body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.post div.content div.response div.block pre { + font-family: "Anonymous Pro", "Menlo", "Consolas", "Bitstream Vera Sans Mono", "Courier New", monospace; + padding: 10px; + font-size: 0.9em; + max-height: 400px; + overflow-y: auto; +} + +body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.put { + float: none; + clear: both; + overflow: hidden; + display: block; + margin: 0 0 10px; + padding: 0; +} + +body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.put div.heading { + float: none; + clear: both; + overflow: hidden; + display: block; + margin: 0; + padding: 0; + background-color: #f9f2e9; + border: 1px solid #f0e0ca; +} + +body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.put div.heading h3 { + display: block; + clear: none; + float: left; + width: auto; + margin: 0; + padding: 0; + line-height: 1.1em; + color: black; +} + +body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.put div.heading h3 span { + margin: 0; + padding: 0; +} + +body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.put div.heading h3 span.http_method a { + text-transform: uppercase; + background-color: #c5862b; + text-decoration: none; + color: white; + display: inline-block; + width: 50px; + font-size: 0.7em; + text-align: center; + padding: 7px 0 4px; + -moz-border-radius: 2px; + -webkit-border-radius: 2px; + -o-border-radius: 2px; + -ms-border-radius: 2px; + -khtml-border-radius: 2px; + border-radius: 2px; +} + +body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.put div.heading h3 span.path { + padding-left: 10px; +} + +body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.put div.heading h3 span.path a { + color: black; + text-decoration: none; +} + +body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.put div.heading h3 span.path a:hover { + text-decoration: underline; +} + +body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.put div.heading ul.options { + overflow: hidden; + padding: 0; + display: block; + clear: none; + float: right; + margin: 6px 10px 0 0; +} + +body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.put div.heading ul.options li { + float: left; + clear: none; + margin: 0; + padding: 2px 10px; + border-right: 1px solid #dddddd; +} + +body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.put div.heading ul.options li:first-child, body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.put div.heading ul.options li.first { + padding-left: 0; +} + +body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.put div.heading ul.options li:last-child, body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.put div.heading ul.options li.last { + padding-right: 0; + border-right: none; +} + +body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.put div.heading ul.options li { + border-right-color: #f0e0ca; + color: #c5862b; + font-size: 0.9em; +} + +body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.put div.heading ul.options li a { + color: #c5862b; + text-decoration: none; +} + +body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.put div.heading ul.options li a:hover, body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.put div.heading ul.options li a:active, body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.put div.heading ul.options li a.active { + text-decoration: underline; +} + +body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.put div.content { + background-color: #faf5ee; + border: 1px solid #f0e0ca; + border-top: none; + padding: 10px; + -moz-border-radius-bottomleft: 6px; + -webkit-border-bottom-left-radius: 6px; + -o-border-bottom-left-radius: 6px; + -ms-border-bottom-left-radius: 6px; + -khtml-border-bottom-left-radius: 6px; + border-bottom-left-radius: 6px; + -moz-border-radius-bottomright: 6px; + -webkit-border-bottom-right-radius: 6px; + -o-border-bottom-right-radius: 6px; + -ms-border-bottom-right-radius: 6px; + -khtml-border-bottom-right-radius: 6px; + border-bottom-right-radius: 6px; + margin: 0 0 20px; +} + +body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.put div.content h4 { + color: #c5862b; + font-size: 1.1em; + margin: 0; + padding: 15px 0 5px; +} + +body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.put div.content form input[type='text'].error { + outline: 2px solid black; + outline-color: #cc0000; +} + +body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.put div.content div.sandbox_header { + float: none; + clear: both; + overflow: hidden; + display: block; +} + +body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.put div.content div.sandbox_header input.submit { + display: block; + clear: none; + float: left; + padding: 6px 8px; +} + +body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.put div.content div.sandbox_header img { + display: block; + clear: none; + float: right; +} + +body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.put div.content div.sandbox_header a { + padding: 4px 0 0 10px; + color: #dcb67f; + display: inline-block; + font-size: 0.9em; +} + +body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.put div.content div.response div.block pre { + font-family: "Anonymous Pro", "Menlo", "Consolas", "Bitstream Vera Sans Mono", "Courier New", monospace; + padding: 10px; + font-size: 0.9em; + max-height: 400px; + overflow-y: auto; +} + +body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.patch { + float: none; + clear: both; + overflow: hidden; + display: block; + margin: 0 0 10px; + padding: 0; +} + +body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.patch div.heading { + float: none; + clear: both; + overflow: hidden; + display: block; + margin: 0; + padding: 0; + background-color: #FCE9E3; + border: 1px solid #F5D5C3; +} + +body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.patch div.heading h3 { + display: block; + clear: none; + float: left; + width: auto; + margin: 0; + padding: 0; + line-height: 1.1em; + color: black; +} + +body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.patch div.heading h3 span { + margin: 0; + padding: 0; +} + +body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.patch div.heading h3 span.http_method a { + text-transform: uppercase; + background-color: #D38042; + text-decoration: none; + color: white; + display: inline-block; + width: 50px; + font-size: 0.7em; + text-align: center; + padding: 7px 0 4px 0; + -moz-border-radius: 2px; + -webkit-border-radius: 2px; + -o-border-radius: 2px; + -ms-border-radius: 2px; + -khtml-border-radius: 2px; + border-radius: 2px; +} + +body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.patch div.heading h3 span.path { + padding-left: 10px; +} + +body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.patch div.heading h3 span.path a { + color: black; + text-decoration: none; +} + +body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.patch div.heading h3 span.path a:hover { + text-decoration: underline; +} + +body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.patch div.heading ul.options { + overflow: hidden; + padding: 0; + display: block; + clear: none; + float: right; + margin: 6px 10px 0 0; +} + +body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.patch div.heading ul.options li { + float: left; + clear: none; + margin: 0; + padding: 2px 10px; + border-right: 1px solid #dddddd; +} + +body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.patch div.heading ul.options li:first-child, body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.patch div.heading ul.options li.first { + padding-left: 0; +} + +body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.patch div.heading ul.options li:last-child, body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.patch div.heading ul.options li.last { + padding-right: 0; + border-right: none; +} + +body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.patch div.heading ul.options li { + border-right-color: #f0cecb; + color: #D38042; + font-size: 0.9em; +} + +body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.patch div.heading ul.options li a { + color: #D38042; + text-decoration: none; +} + +body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.patch div.heading ul.options li a:hover, body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.patch div.heading ul.options li a:active, body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.patch div.heading ul.options li a.active { + text-decoration: underline; +} + +body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.patch div.content { + background-color: #faf0ef; + border: 1px solid #f0cecb; + border-top: none; + padding: 10px; + -moz-border-radius-bottomleft: 6px; + -webkit-border-bottom-left-radius: 6px; + -o-border-bottom-left-radius: 6px; + -ms-border-bottom-left-radius: 6px; + -khtml-border-bottom-left-radius: 6px; + border-bottom-left-radius: 6px; + -moz-border-radius-bottomright: 6px; + -webkit-border-bottom-right-radius: 6px; + -o-border-bottom-right-radius: 6px; + -ms-border-bottom-right-radius: 6px; + -khtml-border-bottom-right-radius: 6px; + border-bottom-right-radius: 6px; + margin: 0 0 20px; +} + +body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.patch div.content h4 { + color: #D38042; + font-size: 1.1em; + margin: 0; + padding: 15px 0 5px; +} + +body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.patch div.content form input[type='text'].error { + outline: 2px solid black; + outline-color: #F5D5C3; +} + +body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.patch div.content div.sandbox_header { + float: none; + clear: both; + overflow: hidden; + display: block; +} + +body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.patch div.content div.sandbox_header input.submit { + display: block; + clear: none; + float: left; + padding: 6px 8px; +} + +body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.patch div.content div.sandbox_header img { + display: block; + clear: none; + float: right; +} + +body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.patch div.content div.sandbox_header a { + padding: 4px 0 0 10px; + color: #dcb67f; + display: inline-block; + font-size: 0.9em; +} + +body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.patch div.content div.response div.block pre { + font-family: "Anonymous Pro", "Menlo", "Consolas", "Bitstream Vera Sans Mono", "Courier New", monospace; + padding: 10px; + font-size: 0.9em; + max-height: 400px; + overflow-y: auto; +} + +body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.head { + float: none; + clear: both; + overflow: hidden; + display: block; + margin: 0 0 10px 0; + padding: 0 0 0 0px; +} + +body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.head div.heading { + float: none; + clear: both; + overflow: hidden; + display: block; + margin: 0 0 0 0; + padding: 0; + background-color: #fcffcd; + border: 1px solid black; + border-color: #ffd20f; +} + +body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.head div.heading h3 { + display: block; + clear: none; + float: left; + width: auto; + margin: 0; + padding: 0; + line-height: 1.1em; + color: black; +} + +body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.head div.heading h3 span { + margin: 0; + padding: 0; +} + +body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.head div.heading h3 span.http_method a { + text-transform: uppercase; + background-color: #ffd20f; + text-decoration: none; + color: white; + display: inline-block; + width: 50px; + font-size: 0.7em; + text-align: center; + padding: 7px 0 4px 0; + -moz-border-radius: 2px; + -webkit-border-radius: 2px; + -o-border-radius: 2px; + -ms-border-radius: 2px; + -khtml-border-radius: 2px; + border-radius: 2px; +} + +body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.head div.heading h3 span.path { + padding-left: 10px; +} + +body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.head div.heading h3 span.path a { + color: black; + text-decoration: none; +} + +body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.head div.heading h3 span.path a:hover { + text-decoration: underline; +} + +body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.head div.heading ul.options { + float: none; + clear: both; + overflow: hidden; + margin: 0; + padding: 0; + display: block; + clear: none; + float: right; + margin: 6px 10px 0 0; +} + +body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.head div.heading ul.options li { + float: left; + clear: none; + margin: 0; + padding: 2px 10px; + border-right: 1px solid #dddddd; +} + +body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.head div.heading ul.options li:first-child, body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.head div.heading ul.options li.first { + padding-left: 0; +} + +body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.head div.heading ul.options li:last-child, body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.head div.heading ul.options li.last { + padding-right: 0; + border-right: none; +} + +body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.head div.heading ul.options li { + border-right-color: #ffd20f; + color: #ffd20f; + font-size: 0.9em; +} + +body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.head div.heading ul.options li a { + color: #ffd20f; + text-decoration: none; +} + +body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.head div.heading ul.options li a:hover, body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.head div.heading ul.options li a:active, body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.head div.heading ul.options li a.active { + text-decoration: underline; +} + +body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.head div.content { + background-color: #fcffcd; + border: 1px solid black; + border-color: #ffd20f; + border-top: none; + padding: 10px; + -moz-border-radius-bottomleft: 6px; + -webkit-border-bottom-left-radius: 6px; + -o-border-bottom-left-radius: 6px; + -ms-border-bottom-left-radius: 6px; + -khtml-border-bottom-left-radius: 6px; + border-bottom-left-radius: 6px; + -moz-border-radius-bottomright: 6px; + -webkit-border-bottom-right-radius: 6px; + -o-border-bottom-right-radius: 6px; + -ms-border-bottom-right-radius: 6px; + -khtml-border-bottom-right-radius: 6px; + border-bottom-right-radius: 6px; + margin: 0 0 20px 0; +} + +body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.head div.content h4 { + color: #ffd20f; + font-size: 1.1em; + margin: 0; + padding: 15px 0 5px 0px; +} + +body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.head div.content form input[type='text'].error { + outline: 2px solid black; + outline-color: #cc0000; +} + +body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.head div.content div.sandbox_header { + float: none; + clear: both; + overflow: hidden; + display: block; +} + +body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.head div.content div.sandbox_header input.submit { + display: block; + clear: none; + float: left; + padding: 6px 8px; +} + +body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.head div.content div.sandbox_header img { + display: block; + display: block; + clear: none; + float: right; +} + +body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.head div.content div.sandbox_header a { + padding: 4px 0 0 10px; + color: #6fc992; + display: inline-block; + font-size: 0.9em; +} + +body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.head div.content div.response div.block { + background-color: #fcf6db; + border: 1px solid black; + border-color: #e5e0c6; +} + +body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.head div.content div.response div.block pre { + font-family: "Anonymous Pro", "Menlo", "Consolas", "Bitstream Vera Sans Mono", "Courier New", monospace; + padding: 10px; + font-size: 0.9em; + max-height: 400px; + overflow-y: auto; +} + +body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.delete { + float: none; + clear: both; + overflow: hidden; + display: block; + margin: 0 0 10px; + padding: 0; +} + +body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.delete div.heading { + float: none; + clear: both; + overflow: hidden; + display: block; + margin: 0; + padding: 0; + background-color: #f5e8e8; + border: 1px solid #e8c6c7; +} + +body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.delete div.heading h3 { + display: block; + clear: none; + float: left; + width: auto; + margin: 0; + padding: 0; + line-height: 1.1em; + color: black; +} + +body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.delete div.heading h3 span { + margin: 0; + padding: 0; +} + +body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.delete div.heading h3 span.http_method a { + text-transform: uppercase; + background-color: #a41e22; + text-decoration: none; + color: white; + display: inline-block; + width: 50px; + font-size: 0.7em; + text-align: center; + padding: 7px 0 4px 0; + -moz-border-radius: 2px; + -webkit-border-radius: 2px; + -o-border-radius: 2px; + -ms-border-radius: 2px; + -khtml-border-radius: 2px; + border-radius: 2px; +} + +body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.delete div.heading h3 span.path { + padding-left: 10px; +} + +body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.delete div.heading h3 span.path a { + color: black; + text-decoration: none; +} + +body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.delete div.heading h3 span.path a:hover { + text-decoration: underline; +} + +body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.delete div.heading ul.options { + overflow: hidden; + padding: 0; + display: block; + clear: none; + float: right; + margin: 6px 10px 0 0; +} + +body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.delete div.heading ul.options li { + float: left; + clear: none; + margin: 0; + padding: 2px 10px; + border-right: 1px solid #dddddd; +} + +body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.delete div.heading ul.options li:first-child, body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.delete div.heading ul.options li.first { + padding-left: 0; +} + +body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.delete div.heading ul.options li:last-child, body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.delete div.heading ul.options li.last { + padding-right: 0; + border-right: none; +} + +body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.delete div.heading ul.options li { + border-right-color: #e8c6c7; + color: #a41e22; + font-size: 0.9em; +} + +body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.delete div.heading ul.options li a { + color: #a41e22; + text-decoration: none; +} + +body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.delete div.heading ul.options li a:hover, body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.delete div.heading ul.options li a:active, body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.delete div.heading ul.options li a.active { + text-decoration: underline; +} + +body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.delete div.content { + background-color: #f7eded; + border: 1px solid #e8c6c7; + border-top: none; + padding: 10px; + -moz-border-radius-bottomleft: 6px; + -webkit-border-bottom-left-radius: 6px; + -o-border-bottom-left-radius: 6px; + -ms-border-bottom-left-radius: 6px; + -khtml-border-bottom-left-radius: 6px; + border-bottom-left-radius: 6px; + -moz-border-radius-bottomright: 6px; + -webkit-border-bottom-right-radius: 6px; + -o-border-bottom-right-radius: 6px; + -ms-border-bottom-right-radius: 6px; + -khtml-border-bottom-right-radius: 6px; + border-bottom-right-radius: 6px; + margin: 0 0 20px 0; +} + +body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.delete div.content h4 { + color: #a41e22; + font-size: 1.1em; + margin: 0; + padding: 15px 0 5px; +} + +body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.delete div.content form input[type='text'].error { + outline: 2px solid black; + outline-color: #cc0000; +} + +body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.delete div.content div.sandbox_header { + float: none; + clear: both; + overflow: hidden; + display: block; +} + +body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.delete div.content div.sandbox_header input.submit { + display: block; + clear: none; + float: left; + padding: 6px 8px; +} + +body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.delete div.content div.sandbox_header img { + display: block; + clear: none; + float: right; +} + +body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.delete div.content div.sandbox_header a { + padding: 4px 0 0 10px; + color: #c8787a; + display: inline-block; + font-size: 0.9em; +} + +body ul#resources li.resource ul.endpoints li.endpoint ul.operations li.operation.delete div.content div.response div.block pre { + font-family: "Anonymous Pro", "Menlo", "Consolas", "Bitstream Vera Sans Mono", "Courier New", monospace; + padding: 10px; + font-size: 0.9em; + max-height: 400px; + overflow-y: auto; +} + + +.model-signature { + font-family: "Droid Sans", sans-serif; + font-size: 1em; + line-height: 1.5em; +} + +.model-signature .description div { + font-size: 0.9em; + line-height: 1.5em; + margin-left: 1em; +} + +.model-signature .description .strong { + font-weight: bold; + color: #000; + font-size: .9em; +} + +.model-signature .description .stronger { + font-weight: bold; + color: #000; +} + +.model-signature .signature-nav a { + text-decoration: none; + color: #AAA; +} + +.model-signature pre { + font-size: .85em; + line-height: 1.2em; + overflow: auto; + max-height: 200px; + cursor: pointer; +} + +.model-signature pre:hover { + background-color: #ffffdd; +} + +.model-signature .snippet small { + font-size: 0.75em; +} + +.model-signature .signature-container { + clear: both; +} + +.model-signature .signature-nav a:hover { + text-decoration: underline; + color: black; +} + +.model-signature .signature-nav .selected { + color: black; + text-decoration: none; +} + +.model-signature ul.signature-nav { + display: block; + margin: 0; + padding: 0; +} + +.model-signature ul.signature-nav li { + float: left; + margin: 0 5px 5px 0; + padding: 2px 5px 2px 0; + border-right: 1px solid #ddd; +} + +.model-signature ul.signature-nav li:last-child { + padding-right: 0; + border-right: none; +} + +.model-signature .propName { + font-weight: bold; +} +.model-signature .propType { + color: #5555aa; +} +.model-signature .propOptKey { + font-style: italic; +} +.model-signature .propOpt { + color: #555; +} + +pre code { + background: none; +} + +.content pre { + font-size: 12px; + margin-top: 5px; + padding: 5px; +} + +.content > .content-type > div > label { + clear: both; + display: block; + color: #0F6AB4; + font-size: 1.1em; + margin: 0; + padding: 15px 0 5px; +} + +.swagger-ui-wrap { + max-width: 960px; + margin-left: auto; + margin-right: auto; +} + +.icon-btn { + cursor: pointer; +} + +#message-bar { + min-height: 30px; + text-align: center; + padding-top: 10px; +} + +.message-success { + color: #89BF04; +} + +.message-fail { + color: #cc0000; +} \ No newline at end of file diff --git a/src/main/webapp/swagger/images/logo_small.png b/src/main/webapp/swagger/images/logo_small.png new file mode 100644 index 00000000..5496a655 Binary files /dev/null and b/src/main/webapp/swagger/images/logo_small.png differ diff --git a/src/main/webapp/swagger/images/pet_store_api.png b/src/main/webapp/swagger/images/pet_store_api.png new file mode 100644 index 00000000..f9f9cd4a Binary files /dev/null and b/src/main/webapp/swagger/images/pet_store_api.png differ diff --git a/src/main/webapp/swagger/images/throbber.gif b/src/main/webapp/swagger/images/throbber.gif new file mode 100644 index 00000000..06393889 Binary files /dev/null and b/src/main/webapp/swagger/images/throbber.gif differ diff --git a/src/main/webapp/swagger/images/wordnik_api.png b/src/main/webapp/swagger/images/wordnik_api.png new file mode 100644 index 00000000..dca4f145 Binary files /dev/null and b/src/main/webapp/swagger/images/wordnik_api.png differ diff --git a/src/main/webapp/swagger/index.html b/src/main/webapp/swagger/index.html new file mode 100644 index 00000000..1abf4612 --- /dev/null +++ b/src/main/webapp/swagger/index.html @@ -0,0 +1,80 @@ + + + + Swagger UI + + + + + + + + + + + + + + + + + + + + +
+   +
+ +
+ +
+ + + + diff --git a/src/main/webapp/swagger/lib/backbone-min.js b/src/main/webapp/swagger/lib/backbone-min.js new file mode 100644 index 00000000..c1c0d4ff --- /dev/null +++ b/src/main/webapp/swagger/lib/backbone-min.js @@ -0,0 +1,38 @@ +// Backbone.js 0.9.2 + +// (c) 2010-2012 Jeremy Ashkenas, DocumentCloud Inc. +// Backbone may be freely distributed under the MIT license. +// For all details and documentation: +// http://backbonejs.org +(function(){var l=this,y=l.Backbone,z=Array.prototype.slice,A=Array.prototype.splice,g;g="undefined"!==typeof exports?exports:l.Backbone={};g.VERSION="0.9.2";var f=l._;!f&&"undefined"!==typeof require&&(f=require("underscore"));var i=l.jQuery||l.Zepto||l.ender;g.setDomLibrary=function(a){i=a};g.noConflict=function(){l.Backbone=y;return this};g.emulateHTTP=!1;g.emulateJSON=!1;var p=/\s+/,k=g.Events={on:function(a,b,c){var d,e,f,g,j;if(!b)return this;a=a.split(p);for(d=this._callbacks||(this._callbacks= +{});e=a.shift();)f=(j=d[e])?j.tail:{},f.next=g={},f.context=c,f.callback=b,d[e]={tail:g,next:j?j.next:f};return this},off:function(a,b,c){var d,e,h,g,j,q;if(e=this._callbacks){if(!a&&!b&&!c)return delete this._callbacks,this;for(a=a?a.split(p):f.keys(e);d=a.shift();)if(h=e[d],delete e[d],h&&(b||c))for(g=h.tail;(h=h.next)!==g;)if(j=h.callback,q=h.context,b&&j!==b||c&&q!==c)this.on(d,j,q);return this}},trigger:function(a){var b,c,d,e,f,g;if(!(d=this._callbacks))return this;f=d.all;a=a.split(p);for(g= +z.call(arguments,1);b=a.shift();){if(c=d[b])for(e=c.tail;(c=c.next)!==e;)c.callback.apply(c.context||this,g);if(c=f){e=c.tail;for(b=[b].concat(g);(c=c.next)!==e;)c.callback.apply(c.context||this,b)}}return this}};k.bind=k.on;k.unbind=k.off;var o=g.Model=function(a,b){var c;a||(a={});b&&b.parse&&(a=this.parse(a));if(c=n(this,"defaults"))a=f.extend({},c,a);b&&b.collection&&(this.collection=b.collection);this.attributes={};this._escapedAttributes={};this.cid=f.uniqueId("c");this.changed={};this._silent= +{};this._pending={};this.set(a,{silent:!0});this.changed={};this._silent={};this._pending={};this._previousAttributes=f.clone(this.attributes);this.initialize.apply(this,arguments)};f.extend(o.prototype,k,{changed:null,_silent:null,_pending:null,idAttribute:"id",initialize:function(){},toJSON:function(){return f.clone(this.attributes)},get:function(a){return this.attributes[a]},escape:function(a){var b;if(b=this._escapedAttributes[a])return b;b=this.get(a);return this._escapedAttributes[a]=f.escape(null== +b?"":""+b)},has:function(a){return null!=this.get(a)},set:function(a,b,c){var d,e;f.isObject(a)||null==a?(d=a,c=b):(d={},d[a]=b);c||(c={});if(!d)return this;d instanceof o&&(d=d.attributes);if(c.unset)for(e in d)d[e]=void 0;if(!this._validate(d,c))return!1;this.idAttribute in d&&(this.id=d[this.idAttribute]);var b=c.changes={},h=this.attributes,g=this._escapedAttributes,j=this._previousAttributes||{};for(e in d){a=d[e];if(!f.isEqual(h[e],a)||c.unset&&f.has(h,e))delete g[e],(c.silent?this._silent: +b)[e]=!0;c.unset?delete h[e]:h[e]=a;!f.isEqual(j[e],a)||f.has(h,e)!=f.has(j,e)?(this.changed[e]=a,c.silent||(this._pending[e]=!0)):(delete this.changed[e],delete this._pending[e])}c.silent||this.change(c);return this},unset:function(a,b){(b||(b={})).unset=!0;return this.set(a,null,b)},clear:function(a){(a||(a={})).unset=!0;return this.set(f.clone(this.attributes),a)},fetch:function(a){var a=a?f.clone(a):{},b=this,c=a.success;a.success=function(d,e,f){if(!b.set(b.parse(d,f),a))return!1;c&&c(b,d)}; +a.error=g.wrapError(a.error,b,a);return(this.sync||g.sync).call(this,"read",this,a)},save:function(a,b,c){var d,e;f.isObject(a)||null==a?(d=a,c=b):(d={},d[a]=b);c=c?f.clone(c):{};if(c.wait){if(!this._validate(d,c))return!1;e=f.clone(this.attributes)}a=f.extend({},c,{silent:!0});if(d&&!this.set(d,c.wait?a:c))return!1;var h=this,i=c.success;c.success=function(a,b,e){b=h.parse(a,e);if(c.wait){delete c.wait;b=f.extend(d||{},b)}if(!h.set(b,c))return false;i?i(h,a):h.trigger("sync",h,a,c)};c.error=g.wrapError(c.error, +h,c);b=this.isNew()?"create":"update";b=(this.sync||g.sync).call(this,b,this,c);c.wait&&this.set(e,a);return b},destroy:function(a){var a=a?f.clone(a):{},b=this,c=a.success,d=function(){b.trigger("destroy",b,b.collection,a)};if(this.isNew())return d(),!1;a.success=function(e){a.wait&&d();c?c(b,e):b.trigger("sync",b,e,a)};a.error=g.wrapError(a.error,b,a);var e=(this.sync||g.sync).call(this,"delete",this,a);a.wait||d();return e},url:function(){var a=n(this,"urlRoot")||n(this.collection,"url")||t(); +return this.isNew()?a:a+("/"==a.charAt(a.length-1)?"":"/")+encodeURIComponent(this.id)},parse:function(a){return a},clone:function(){return new this.constructor(this.attributes)},isNew:function(){return null==this.id},change:function(a){a||(a={});var b=this._changing;this._changing=!0;for(var c in this._silent)this._pending[c]=!0;var d=f.extend({},a.changes,this._silent);this._silent={};for(c in d)this.trigger("change:"+c,this,this.get(c),a);if(b)return this;for(;!f.isEmpty(this._pending);){this._pending= +{};this.trigger("change",this,a);for(c in this.changed)!this._pending[c]&&!this._silent[c]&&delete this.changed[c];this._previousAttributes=f.clone(this.attributes)}this._changing=!1;return this},hasChanged:function(a){return!arguments.length?!f.isEmpty(this.changed):f.has(this.changed,a)},changedAttributes:function(a){if(!a)return this.hasChanged()?f.clone(this.changed):!1;var b,c=!1,d=this._previousAttributes,e;for(e in a)if(!f.isEqual(d[e],b=a[e]))(c||(c={}))[e]=b;return c},previous:function(a){return!arguments.length|| +!this._previousAttributes?null:this._previousAttributes[a]},previousAttributes:function(){return f.clone(this._previousAttributes)},isValid:function(){return!this.validate(this.attributes)},_validate:function(a,b){if(b.silent||!this.validate)return!0;var a=f.extend({},this.attributes,a),c=this.validate(a,b);if(!c)return!0;b&&b.error?b.error(this,c,b):this.trigger("error",this,c,b);return!1}});var r=g.Collection=function(a,b){b||(b={});b.model&&(this.model=b.model);b.comparator&&(this.comparator=b.comparator); +this._reset();this.initialize.apply(this,arguments);a&&this.reset(a,{silent:!0,parse:b.parse})};f.extend(r.prototype,k,{model:o,initialize:function(){},toJSON:function(a){return this.map(function(b){return b.toJSON(a)})},add:function(a,b){var c,d,e,g,i,j={},k={},l=[];b||(b={});a=f.isArray(a)?a.slice():[a];c=0;for(d=a.length;c=b))this.iframe=i('