this commit removes the usage of .form-group class which is deprecated since BS5. Here is the css rules that was used: a) https://github.com/twbs/bootstrap/blob/8fa0d3010112dca5dd6dd501173415856001ba8b/dist/css/bootstrap.css#L1997 As we can see, it simply adds a `margin-bottom` of `1rem` which corresponds to the `.mb-3` BS class. b) https://github.com/twbs/bootstrap/blob/8fa0d3010112dca5dd6dd501173415856001ba8b/dist/css/bootstrap.css#L2326 As we already checked all `form-inline` in [1] and [2], we don't have to do anything about these rules. '''Breaking change: Dropped form-specific layout classes for our grid system. Use our grid and utilities instead of .form-group, .form-row, or .form-inline.''' https://getbootstrap.com/docs/5.0/migration/#forms Notes: - `position: relative` is already on `#new-password-group`. - `.field-db`, `#editor-media-image`, `.unsplash_img_container` and `#url-form-group` seems unused. - Sometimes margins are unnecessary because of blocks overlapping. (e.g. `margin-bottom` is not needed if margin-top is set on the following node) - CSS rules applied on `.s_website_form_rows > .form-group` are now in the XML by adding `mb-0 py-2` BS classes. Follow-up of: [1] https://github.com/odoo/odoo/pull/97967 [2] https://github.com/odoo/enterprise/pull/30343 closes odoo/odoo#100052 Related: odoo/enterprise#31261 Signed-off-by: Adrien Dieudonné (adr) <adr@odoo.com>
87 lines
5.3 KiB
XML
87 lines
5.3 KiB
XML
<?xml version="1.0" encoding="utf-8"?>
|
|
<odoo>
|
|
<template id="create_shorten_url">
|
|
<div class="o_website_links_create_tracked_url">
|
|
<div class="container">
|
|
<h1 class="o_page_header">Link Tracker</h1>
|
|
<div class="notification"></div>
|
|
|
|
<div class="row">
|
|
<div class="col-md-7">
|
|
<form id="o_website_links_link_tracker_form">
|
|
|
|
<div class="mb-3 row">
|
|
<label class="col-md-3 col-form-label text-start">URL</label>
|
|
|
|
<div class="col-md-9">
|
|
<input type="text" id="url" class="form-control required-form-control" required="True" placeholder="e.g. https://www.odoo.com/contactus" t-att-value="u"/>
|
|
</div>
|
|
</div>
|
|
|
|
<div class="o_website_links_utm_forms">
|
|
<div class="mb-3 row">
|
|
<label class="col-md-3 col-form-label">Campaign <i class="fa fa-info-circle" data-bs-toggle="tooltip" data-bs-placement="top" role="img" aria-label="Tooltip info" title="Defines the context of your link. It might be an event you want to promote or a special promotion."></i></label>
|
|
|
|
<div class="col-md-9">
|
|
<input type="hidden" class="form-control" id="campaign-select"/>
|
|
</div>
|
|
</div>
|
|
|
|
<div class="mb-3 row">
|
|
<label class="col-md-3 col-form-label">Medium <i class="fa fa-info-circle" data-bs-toggle="tooltip" data-bs-placement="top" role="img" aria-label="Tooltip info" title="Defines the medium used to share your link. It might be an email, or a Facebook Ads for instance."></i></label>
|
|
|
|
<div class="col-md-9">
|
|
<input type="hidden" class="form-control" id="channel-select" />
|
|
</div>
|
|
</div>
|
|
|
|
<div class="mb-3 row">
|
|
<label class="col-md-3 col-form-label">Source <i class="fa fa-info-circle" data-bs-toggle="tooltip" data-bs-placement="top" role="img" aria-label="Tooltip info" title="Defines the source from which your traffic will come from, Facebook or Twitter for instance."></i></label>
|
|
|
|
<div class="col-md-9">
|
|
<input type="hidden" class="form-control" id="source-select" />
|
|
</div>
|
|
</div>
|
|
</div>
|
|
|
|
<div class="mb-3 row">
|
|
<div class="offset-md-3 col-md-9">
|
|
<button type="submit" class="btn btn-primary" id="btn_shorten_url" data-clipboard-text="">Get tracked link</button>
|
|
|
|
<span id="generated_tracked_link" style="display:none;" class="text-muted"></span>
|
|
</div>
|
|
</div>
|
|
</form>
|
|
</div>
|
|
|
|
<div class="offset-md-1 col-md-3 d-none d-md-block">
|
|
<p class="text-muted text-justify">Share this page with a <strong>short link</strong> that includes <strong>analytics trackers</strong>.</p>
|
|
<p class="text-muted text-justify">Those trackers can be used in Google Analytics to track clicks and visitors, or in Odoo reports to track opportunities and related revenues.</p>
|
|
</div>
|
|
</div>
|
|
|
|
<h2 class="o_page_header">Your tracked links
|
|
<small class="float-end d-none d-md-block" id="filters">
|
|
<ul class="nav nav-tabs nav-tabs-inline graph-tabs" role="tablist">
|
|
<li class="nav-item"><a aria-controls="filter-newest-links" href="#" class="nav-link active" id="filter-newest-links" role="tab" data-bs-toggle="tab">Newest</a></li>
|
|
<li class="nav-item"><a aria-controls="filter-most-clicked-links" href="#" class="nav-link" id="filter-most-clicked-links" role="tab" data-bs-toggle="tab">Most Clicked</a></li>
|
|
<li class="nav-item"><a aria-controls="filter-recently-used-links" href="#" class="nav-link" id="filter-recently-used-links" role="tab" data-bs-toggle="tab">Recently Used</a></li>
|
|
</ul>
|
|
</small>
|
|
</h2>
|
|
|
|
<div id="o_website_links_recent_links">
|
|
<div class="o_website_links_recent_links_notification"></div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</template>
|
|
|
|
<template id="page_shorten_url" name="Link Tracker">
|
|
<t t-call="website.layout">
|
|
<t t-call="website_links.create_shorten_url"/>
|
|
</t>
|
|
</template>
|
|
|
|
</odoo>
|