/* * Copyright 2017 Google Inc. All rights reserved. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. */ "use strict"; /* eslint require-jsdoc: "off" */ var body; function bodyReset() { body = ''; } function bodyH1(txt) { body += '

' + txt + '

'; } function bodyH2(txt) { body += '

' + txt + '

'; } function bodyH3(txt) { body += '

' + txt + '

'; } function bodyH4(txt) { body += '

' + txt + '

'; } function bodyPar(txt) { body += '

' + txt + '

'; } function bodyAdd(txt) { body += txt; } var bodyTableBodyAdded = false; function bodyTableStart(width) { bodyTableBodyAdded = false; if (width) { body += ''; } else body += '
'; } function bodyTableTh(tth) { body += ''; for (var ii = 0; ii < tth.length; ii++) body += ''; body += ''; } function bodyTableTd(ttd) { if (!bodyTableBodyAdded) body += ''; body += ''; for (var ii = 0; ii < ttd.length; ii++) body += ''; body += ''; } function bodyTableTdStyle(ttd, style) { if (!bodyTableBodyAdded) body += ''; body += ''; for (var ii = 0; ii < ttd.length; ii++) body += ''; body += ''; } function bodyTableTdStyleProp(ttd) { if (!bodyTableBodyAdded) body += ''; body += ''; for (var ii = 0; ii < ttd.length; ii++) if (ttd[ii].style === undefined) body += ''; else body += ''; body += ''; } function bodyTableEnd() { body += '
' + tth[ii] + '
' + ttd[ii] + '
' + ttd[ii] + '
' + ttd[ii].txt + ' ' + ttd[ii].txt + '
'; } function bodyGet() { return body; } module.exports.bodyReset = bodyReset; module.exports.bodyH1 = bodyH1; module.exports.bodyH2 = bodyH2; module.exports.bodyH3 = bodyH3; module.exports.bodyH4 = bodyH4; module.exports.bodyPar = bodyPar; module.exports.bodyAdd = bodyAdd; module.exports.bodyTableStart = bodyTableStart; module.exports.bodyTableTh = bodyTableTh; module.exports.bodyTableTd = bodyTableTd; module.exports.bodyTableTdStyle = bodyTableTdStyle; module.exports.bodyTableTdStyleProp = bodyTableTdStyleProp; module.exports.bodyTableEnd = bodyTableEnd; module.exports.bodyGet = bodyGet;