在隐藏的div上添加可见内容(Add visible content on hidden div)
我想知道是否有一种方法可以在部分隐藏的div末尾添加内容。
.wrapper { overflow: hidden; width: 200px; height: 30px; margin-top: 10px; } .slide { position: absolute; left: -180px; width: 200px; height: 30px; transition: 1s; text-align: center; } .wrapper:hover .slide { transition: 1s; left: 0; }
<div class="wrapper"> <p class="slide" style="background-color:red;"> test </p> </div> <div class="wrapper"> <p class="slide" style="background-color:blue;"> test </p> </div> <div class="wrapper"> <p class="slide" style="background-color:yellow;"> test </p> </div> <div class="wrapper"> <p class="slide" style="background-color:green;"> test </p> </div>
事情很简单。 这是一个包含4个链接的菜单。 它的部分隐藏,但悬停它完全透露。 我想在div的可见部分添加一个小箭头。 有办法制作吗? 我已经试过这个:
.slide:after { content: ' >'; }
当然这有效,但我认为还有更好的办法!
I wanted to know if there's a way to add content at the end of my div which is partially hidden.
.wrapper { overflow: hidden; width: 200px; height: 30px; margin-top: 10px; } .slide { position: absolute; left: -180px; width: 200px; height: 30px; transition: 1s; text-align: center; } .wrapper:hover .slide { transition: 1s; left: 0; }
<div class="wrapper"> <p class="slide" style="background-color:red;"> test </p> </div> <div class="wrapper"> <p class="slide" style="background-color:blue;"> test </p> </div> <div class="wrapper"> <p class="slide" style="background-color:yellow;"> test </p> </div> <div class="wrapper"> <p class="slide" style="background-color:green;"> test </p> </div>
The thing is simple. It's a menu with 4 links. It's partially hidden, but on hover it's completely revealed. I wanted to add a little arrow on the visible part of the div. Is there a way to make it ? I already try this :
.slide:after { content: ' >'; }
Sure this works but I think there's a better way !
原文:https://stackoverflow.com/questions/27232459
最满意答案
我可以通过更改我的WebAPI控制器来检索发送的语句值,如下所示:
public void Put([FromBody]TinCan.Statement statement) { var actor = statement.actor; var context = statement.context; var target = statement.target; var timestamp = statement.timestamp; var verb = statement.verb; ...................
I was able to retrieve the sent statement values by changing my WebAPI controller as follows:
public void Put([FromBody]TinCan.Statement statement) { var actor = statement.actor; var context = statement.context; var target = statement.target; var timestamp = statement.timestamp; var verb = statement.verb; ...................
相关问答
更多-
TCP/IP模型是一个________。[2023-10-02]
a -
下列中不属于面向对象的编程语言的是?[2022-05-30]
a -
HttpRequest是HttpContext的子集 。 换句话说, HttpContext 包括响应,请求以及与特定请求或响应无关的各种其他数据; 例如Web应用程序,缓存数据,服务器设置和变量,会话状态,经过身份验证的用户等。 例如: HttpContext.Current.Request // This is the current HttpRequest object HttpContext.Current.Response // This is the current HttpResponse o ...
-
我想出了这个,它比我做的简单。 // // Set a variable in the indexer collction // Mock
request = new Mock (); request.SetupGet(r => r["name"]).Returns("Fred Jones"); I figured this one out, it was simpler than I was making it. // // Set a ... -
System.Net.WebRequestMethods.Http .Connect = "CONNECT" .Get = "GET" .Head = "HEAD" .MkCol = "MKCOL" .Post = "POST" .Put = "PUT" 最终,虽然; 因为const表达式被烧录到调用者中,这与使用“GET”等同样,只是没有错字的风险。 System.Net.WebRequestMethods.Http .Connect = "CON ...
-
有可能。 .NET版本4.6.2支持http / 2。 单击“项目”选项卡,然后选择底部的属性 。 然后将.NET版本更改为4.6.2。 此外,我99.9%确定您不应在标题中包含半冒号。 进一步: httpRequest.Headers.Add(":method", "get"); 请求方法不应该在标头中定义。 这样做。 httpRequest.Method = "GET"; 该方案通常由您的网址前缀表示。 即: string webAddr = "https://www.google.com/"; H ...
-
许多人发现AFNetworking框架(来自https://github.com/AFNetworking/AFNetworking的 GIT克隆)使HTTP交互更容易。 具体来说,AFNetworking getPath:和postPath:方法接受一个path ,一个parameters字典,然后是两个块,一个用于success ,一个用于failure 。 因此 { [self getPath: @"users" parameters: @{ @"api_key" : @"AppAPIKey ...
-
从c#中的HTTPRequest中检索Request Payload值(Retrieving the Request Payload values from a HTTPRequest in c#)[2024-03-23]
我可以通过更改我的WebAPI控制器来检索发送的语句值,如下所示: public void Put([FromBody]TinCan.Statement statement) { var actor = statement.actor; var context = statement.context; var target = statement.target; var timestamp = statement.timestamp; var verb = statement. ... -
你有一个无效的HTTP请求。 PUT动词后面应该是你正在放置的资源的名称是asp.net页面。 所以一个有效的请求应该是: PUT /yourpage.aspx Headre1: value1 Header2: value2 在这种情况下,当然你已经知道yourpage.aspx因为你在这个页面中。 You have an invalid HTTP request. What follows the PUT verb should be the name of the resource your are ...
-
奇怪的HttpRequest行为(Odd HttpRequest behaviour)[2022-05-01]
为什么要检查查询字符串参数的请求流? .Net内有很多内置类型来处理HTTP请求。 您可以使用以下代码轻松地从查询字符串中获取正确的NameValueCollection; NameValueCollection queryStringValues = HttpUtility.ParseQueryString(HttpContext.Current.Request.Query.ToLower()); string value = queryStringValues["my_key"]; 在您的代 ...